X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fbackupfile.c;h=7ea76b49e7853516b2938b0fa0170eb4f590f7e1;hb=7f5a14a4366b8696b9f58cc78d8b3a02912ffc6d;hp=0dfa02eace213c3d9b1553675d284521262a22ac;hpb=552a680fa612218b68d4ef2f49bc276b95f6677b;p=gnulib.git diff --git a/lib/backupfile.c b/lib/backupfile.c index 0dfa02eac..7ea76b49e 100644 --- a/lib/backupfile.c +++ b/lib/backupfile.c @@ -25,13 +25,9 @@ # include #endif +#include #include -#include -#if HAVE_STRING_H -# include -#else -# include -#endif +#include #if HAVE_DIRENT_H # include @@ -57,23 +53,7 @@ # define CLOSEDIR(d) closedir (d) #endif -#if HAVE_STDLIB_H -# include -#endif - -#ifndef HAVE_DECL_GETENV -"this configure-time declaration test was not run" -#endif -#if !HAVE_DECL_GETENV -char *getenv (); -#endif - -#ifndef HAVE_DECL_MALLOC -"this configure-time declaration test was not run" -#endif -#if !HAVE_DECL_MALLOC -char *malloc (); -#endif +#include #if HAVE_DIRENT_H || HAVE_NDIR_H || HAVE_SYS_DIR_H || HAVE_SYS_NDIR_H # define HAVE_DIR 1 @@ -111,8 +91,8 @@ char *malloc (); to numbered) backup file name. */ const char *simple_backup_suffix = "~"; -static int max_backup_version PARAMS ((const char *, const char *)); -static int version_number PARAMS ((const char *, const char *, size_t)); +static int max_backup_version (const char *, const char *); +static int version_number (const char *, const char *, size_t); /* Return the name of the new backup file for file FILE, allocated with malloc. Return 0 if out of memory.