aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAlan Brault <alan.brault@incruentatus.net>2011-05-02 18:58:40 -0400
committerJoseph Hunkeler <jhunk@stsci.edu>2012-05-25 14:21:08 -0400
commit0b20b98e9b2e87eb2e9e10f658d2d523b0ee9fb6 (patch)
tree942d28cad437dd20bf29cb60ad58ad4949b87c96 /include
parentdb970762d90a3adda07874ac597928f5305b0a49 (diff)
downloadduser-0b20b98e9b2e87eb2e9e10f658d2d523b0ee9fb6.tar.gz
Remove strcasestr() and strchrnul() checks from configure, using libdusercompat.a instead
Fix Makefile.am bad entry Clean up compat, bring in strcasestr from OpenBSD and strchrnul from uclibc and separate the headers. Remove config.h from strchrnul.c; not needed Fix numerous shadow declaration bugs that could cause problems for Solaris libc Fix bad prototype using in unlink()
Diffstat (limited to 'include')
-rw-r--r--include/cfg.h2
-rw-r--r--include/compat/strcasestr.h4
-rw-r--r--include/compat/strchrnul.h4
-rw-r--r--include/config.h.in6
-rw-r--r--include/duser.h9
-rw-r--r--include/version.h2
6 files changed, 14 insertions, 13 deletions
diff --git a/include/cfg.h b/include/cfg.h
index d3814f3..b50c16b 100644
--- a/include/cfg.h
+++ b/include/cfg.h
@@ -23,7 +23,7 @@
#define CFG_MAX 255
int cfg_open(const char* filename);
-void cfg_close();
+void cfg_close(void);
int cfg_get_key(char* val, const char* key);
#endif
diff --git a/include/compat/strcasestr.h b/include/compat/strcasestr.h
new file mode 100644
index 0000000..67917d0
--- /dev/null
+++ b/include/compat/strcasestr.h
@@ -0,0 +1,4 @@
+#ifndef STRCASESTR_H
+#define STRCASESTR_H
+char *strcasestr(const char *s, const char *find);
+#endif
diff --git a/include/compat/strchrnul.h b/include/compat/strchrnul.h
new file mode 100644
index 0000000..ca12806
--- /dev/null
+++ b/include/compat/strchrnul.h
@@ -0,0 +1,4 @@
+#ifndef STRCHRNUL_H
+#define STRCHRNUL_H
+char *strchrnul(const char* s, int c);
+#endif
diff --git a/include/config.h.in b/include/config.h.in
index 4b1d187..65ae69b 100644
--- a/include/config.h.in
+++ b/include/config.h.in
@@ -37,12 +37,6 @@
/* Define to 1 if you have the `strcasecmp' function. */
#undef HAVE_STRCASECMP
-/* Define to 1 if you have the `strcasestr' function. */
-#undef HAVE_STRCASESTR
-
-/* Define to 1 if you have the `strchrnul' function. */
-#undef HAVE_STRCHRNUL
-
/* Define to 1 if you have the `strdup' function. */
#undef HAVE_STRDUP
diff --git a/include/duser.h b/include/duser.h
index d562b33..345bf49 100644
--- a/include/duser.h
+++ b/include/duser.h
@@ -58,11 +58,11 @@ typedef struct record_t
int pad3;
} record_t;
-void usage();
+void usage(void);
int strval(const char* str);
int strfind(const char* str1, const char* str2);
-int logcleanup();
-int COM(const char* func, char *format, ...);
+int logcleanup(void);
+int COM(const char* func, const char *format, ...);
record_t* find_in_file(const char* filename, const char* needle);
int get_file_count(const char* path);
char** get_file_list(const char* path, int count);
@@ -77,6 +77,5 @@ int user_cmd(const int argc, char* argv[]);
int user_choice(char c);
int user_add(const char* filename, const char* needle);
int user_new_list(const char* fname);
-char *strcasestr(const char *s, const char *find);
-char *strchrnul(const char* s, int c);
+int check_cmd_string(char** args, const char* str2, int count);
#endif
diff --git a/include/version.h b/include/version.h
index 52763c1..ddbf2b7 100644
--- a/include/version.h
+++ b/include/version.h
@@ -5,5 +5,5 @@
#define VER_MINOR "0"
#define VER_OTH " "
-void version();
+void version(void);
#endif