]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Import of code from heimdal
authorHeimdal Developers <heimdal-discuss@sics.se>
Wed, 24 Nov 2010 09:45:03 +0000 (09:45 +0000)
committerJeffrey Altman <jaltman@openafs.org>
Wed, 24 Nov 2010 09:51:45 +0000 (01:51 -0800)
This commit updates the code imported from heimdal to
f317b91b1b4b8d030fc2ab188b6aa526e9e7cb84 (switch-from-svn-to-git-1703-gf317b91)

Upstream changes are:

Jeffrey Altman (1):
      roken: Prototype getopt

Change-Id: I766ff1c19d4dcb74be18ea96d0ea1f24898eb6e9
Reviewed-on: http://gerrit.openafs.org/3379
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
src/external/heimdal-last
src/external/heimdal/roken/getopt.c
src/external/heimdal/roken/roken.h.in

index 4f564b11caf077e2b67b79c2717172a3f1d193a8..61ca17713a518d47ca333f932890b94917417074 100644 (file)
@@ -1 +1 @@
-0cc7b890e2632a7cb26517825deb802f79e838f8
+f317b91b1b4b8d030fc2ab188b6aa526e9e7cb84
index b177b010d8be34e06dd33e9cf6b97a229e1c0dc4..08b099b962b6793ed08705820ee679f9a665731c 100644 (file)
@@ -55,10 +55,7 @@ ROKEN_LIB_VARIABLE char      *optarg; /* argument associated with option */
 #define        EMSG    ""
 
 ROKEN_LIB_FUNCTION int ROKEN_LIB_CALL
-getopt(nargc, nargv, ostr)
-       int nargc;
-       char * const *nargv;
-       const char *ostr;
+getopt(int nargc, char * const *nargv, const char *ostr)
 {
        static char *place = EMSG;              /* option letter processing */
        char *oli;                      /* option letter list index */
index 2fa6dca3494b6d8b15993eb375a2b8e67156223e..755d8f8e6e22d89aa22f3c47afce442c5ca09fbf 100644 (file)
@@ -765,6 +765,15 @@ ROKEN_LIB_FUNCTION int ROKEN_LIB_CALL get_window_size(int fd, struct winsize *);
 ROKEN_LIB_FUNCTION void ROKEN_LIB_CALL vsyslog(int, const char *, va_list);
 #endif
 
+#ifndef HAVE_GETOPT
+#define getopt rk_getopt
+#define optarg rk_optarg
+#define optind rk_optind
+#define opterr rk_opterr
+ROKEN_LIB_FUNCTION int ROKEN_LIB_CALL
+getopt(int nargc, char * const *nargv, const char *ostr);
+#endif
+
 #if !HAVE_DECL_OPTARG
 ROKEN_LIB_VARIABLE extern char *optarg;
 #endif