diff options
author | okan <okan> | 2015-01-19 14:54:16 +0000 |
---|---|---|
committer | okan <okan> | 2015-01-19 14:54:16 +0000 |
commit | 7936b9b2a7c7c3cc06d3fb60c22ed535b610cd63 (patch) | |
tree | 9bb4f55aee479f2aa360ccc1dc07946b17ad09c5 /search.c | |
parent | c412f040df05c7221537a598786e0cea4b35167f (diff) | |
download | cwm-7936b9b2a7c7c3cc06d3fb60c22ed535b610cd63.tar.gz cwm-7936b9b2a7c7c3cc06d3fb60c22ed535b610cd63.tar.xz cwm-7936b9b2a7c7c3cc06d3fb60c22ed535b610cd63.zip |
Switch to limits.h; replace MAXPATHLEN and MAXHOSTNAMELEN with PATH_MAX
and HOST_NAME_MAX+1, respectively. ok doug@
Diffstat (limited to 'search.c')
-rw-r--r-- | search.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/search.c b/search.c index f0b22ce..ac9f632 100644 --- a/search.c +++ b/search.c @@ -18,7 +18,7 @@ * $OpenBSD$ */ -#include <sys/param.h> +#include <sys/types.h> #include <sys/queue.h> #include <assert.h> @@ -26,6 +26,7 @@ #include <errno.h> #include <fnmatch.h> #include <glob.h> +#include <limits.h> #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -172,7 +173,7 @@ search_print_client(struct menu *mi, int list) static void search_match_path(struct menu_q *menuq, struct menu_q *resultq, char *search, int flag) { - char pattern[MAXPATHLEN]; + char pattern[PATH_MAX]; glob_t g; int i; |