Skip to contentSkip to conversation

btrfs-corrupt-blocks: Include limits.h

PATCH Applied Khem Raj 2 participants 2 messages Jan 10, 2016 – Jan 11, 2016 Btrfs file system

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 btrfs-corrupt-blocks: Include limits.h

limits.h is needed for PATH_MAX definition

Fixes

| btrfs-corrupt-block.c: In function 'corrupt_dir_item':
| btrfs-corrupt-block.c:478:12: error: 'PATH_MAX' undeclared (first use in this function)
|   char name[PATH_MAX];
---
 btrfs-corrupt-block.c | 1 +
 1 file changed, 1 insertion(+)
btrfs-corrupt-block.c +1 -0
index 0b26903..c908b7e 100644
@@ -21,6 +21,7 @@
 #include <fcntl.h>
 #include <unistd.h>
 #include <getopt.h>
+#include <limits.h>
 
 #include "kerncompat.h"
 #include "ctree.h"
Signature · 1 line
2.7.0
Applied
#1 lore raw
Quoted 8 lines · Khem Raj

limits.h is needed for PATH_MAX definition

Fixes

| btrfs-corrupt-block.c: In function 'corrupt_dir_item':
| btrfs-corrupt-block.c:478:12: error: 'PATH_MAX' undeclared (first use in this function)
|   char name[PATH_MAX];

Applied, thanks.