From da7b7f7a8af3ee566330ae7c6dceb0eef74a3305 Mon Sep 17 00:00:00 2001 From: Ezra Peisach Date: Sun, 1 Jul 2001 11:39:38 +0000 Subject: [PATCH] * nstrtok.h: New file with prototype for nstrtok * ovload.c: Include nstrtok.h * strtok.c: Include nstrtok.h for prototype. Declare delim as const char * argument. Delete rcsid. * string_table.c: Delete rcsid. * kadm5_create.c (build_name_with_realm): Declare static. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@13536 dc483132-0cff-0310-8789-dd5450dbe970 --- src/kadmin/dbutil/ChangeLog | 13 +++++++++++++ src/kadmin/dbutil/kadm5_create.c | 7 +------ src/kadmin/dbutil/nstrtok.h | 3 +++ src/kadmin/dbutil/ovload.c | 3 +-- src/kadmin/dbutil/string_table.c | 5 ----- src/kadmin/dbutil/strtok.c | 28 ++++------------------------ 6 files changed, 22 insertions(+), 37 deletions(-) create mode 100644 src/kadmin/dbutil/nstrtok.h diff --git a/src/kadmin/dbutil/ChangeLog b/src/kadmin/dbutil/ChangeLog index 66947de1e..3e265b503 100644 --- a/src/kadmin/dbutil/ChangeLog +++ b/src/kadmin/dbutil/ChangeLog @@ -1,3 +1,16 @@ +2001-06-29 Ezra Peisach + + * nstrtok.h: New file with prototype for nstrtok. + + * ovload.c: Include nstrtok.h + + * strtok.c: Include nstrtok.h for prototype. Declare delim as + const char * argument. Delete rcsid. + + * string_table.c: Delete rcsid. + + * kadm5_create.c (build_name_with_realm): Declare static. + 2001-06-21 Ezra Peisach * kdb5_util.c (main): Change optarg to koptarg to prevent diff --git a/src/kadmin/dbutil/kadm5_create.c b/src/kadmin/dbutil/kadm5_create.c index d4f326a39..146010c37 100644 --- a/src/kadmin/dbutil/kadm5_create.c +++ b/src/kadmin/dbutil/kadm5_create.c @@ -1,7 +1,6 @@ /* * Copyright 1993 OpenVision Technologies, Inc., All Rights Reserved. * - * $Id$ * $Source$ */ @@ -31,10 +30,6 @@ * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#if !defined(lint) && !defined(__CODECENTER__) -static char *rcsid = "$Header$"; -#endif - #include "string_table.h" #include @@ -146,7 +141,7 @@ int kadm5_create_magic_princs(kadm5_config_params *params, * * Requires: both strings are null-terminated */ -char *build_name_with_realm(char *name, char *realm) +static char *build_name_with_realm(char *name, char *realm) { char *n; diff --git a/src/kadmin/dbutil/nstrtok.h b/src/kadmin/dbutil/nstrtok.h new file mode 100644 index 000000000..f7f0d4a69 --- /dev/null +++ b/src/kadmin/dbutil/nstrtok.h @@ -0,0 +1,3 @@ +/* Prototype for nstrtok */ +char *nstrtok(char *, const char *delim); + diff --git a/src/kadmin/dbutil/ovload.c b/src/kadmin/dbutil/ovload.c index 350dfb694..15978f8a3 100644 --- a/src/kadmin/dbutil/ovload.c +++ b/src/kadmin/dbutil/ovload.c @@ -8,8 +8,7 @@ #include #include "import_err.h" #include "kdb5_util.h" - -char *nstrtok(); +#include "nstrtok.h" #define LINESIZE 32768 /* XXX */ #define PLURAL(count) (((count) == 1) ? error_message(IMPORT_SINGLE_RECORD) : error_message(IMPORT_PLURAL_RECORDS)) diff --git a/src/kadmin/dbutil/string_table.c b/src/kadmin/dbutil/string_table.c index c5f09f83b..fcf65dcfc 100644 --- a/src/kadmin/dbutil/string_table.c +++ b/src/kadmin/dbutil/string_table.c @@ -1,13 +1,8 @@ /* * Copyright 1993 OpenVision Technologies, Inc., All Rights Reserved. * - * $Header$ */ -#if !defined(lint) && !defined(__CODECENTER__) -static char *rcsid = "$Header$"; -#endif - /* String table of messages for kadm5_create */ char *str_INITING_KCONTEXT = "while initializing the kerberos context"; diff --git a/src/kadmin/dbutil/strtok.c b/src/kadmin/dbutil/strtok.c index 4458e0c0b..80117a31b 100644 --- a/src/kadmin/dbutil/strtok.c +++ b/src/kadmin/dbutil/strtok.c @@ -1,26 +1,8 @@ /* * Copyright 1993 OpenVision Technologies, Inc., All Rights Reserved * - * $Header$ - * - * $Log$ - * Revision 1.1 1996/08/01 18:39:54 bjaspan - * * Makefile.in, Makefile.ov, configure.in, dump.c: add support for - * dump/load of OV*Secure-compatible format. - * - * Revision 1.1.2.1 1996/06/20 21:49:01 marc - * File added to the repository on a branch - * - * Revision 1.1 1993/11/14 23:51:23 shanzer - * Initial revision - * */ -#if !defined(lint) && !defined(__CODECENTER__) -static char *rcsid = "$Header$"; -#endif - - /* * Copyright (c) 1988 Regents of the University of California. * All rights reserved. @@ -40,12 +22,9 @@ static char *rcsid = "$Header$"; * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)strtok.c 5.7 (Berkeley) 6/1/90"; -#endif /* LIBC_SCCS and not lint */ - #include #include +#include "nstrtok.h" /* * Function: nstrtok @@ -71,9 +50,10 @@ static char sccsid[] = "@(#)strtok.c 5.7 (Berkeley) 6/1/90"; char * nstrtok(s, delim) - register char *s, *delim; + register char *s; + register const char *delim; { - register char *spanp; + register const char *spanp; register int c, sc; char *tok; static char *last; -- 2.26.2