[PATCH v1] Include limits.h for PATH_MAX.

Peter Seiderer ps.report at gmx.net
Wed Oct 11 09:22:43 UTC 2017


Fixes the following compile failure when building with musl:

  find_event_devices.c: In function ‘find_event_devices’:
  find_event_devices.c:60:14: error: ‘PATH_MAX’ undeclared (first use in this function)
     char fname[PATH_MAX];
                ^~~~~~~~

Signed-off-by: Peter Seiderer <ps.report at gmx.net>
---
 tools/find_event_devices.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/find_event_devices.c b/tools/find_event_devices.c
index 2a43d54..3a74096 100644
--- a/tools/find_event_devices.c
+++ b/tools/find_event_devices.c
@@ -24,6 +24,7 @@
 
 #define _GNU_SOURCE
 #include <linux/input.h>
+#include <limits.h>
 #include <dirent.h>
 #include <string.h>
 #include <stdio.h>
-- 
2.14.2



More information about the Input-tools mailing list