diff options
author | tjr <tjr@FreeBSD.org> | 2005-10-01 04:56:09 +0000 |
---|---|---|
committer | tjr <tjr@FreeBSD.org> | 2005-10-01 04:56:09 +0000 |
commit | a9df32e6ddacac944e0ee28c6b36c4ff78df717b (patch) | |
tree | d9bca98e355507f4d6cb7dd937884b287076f651 /contrib/cpio/src | |
parent | 97bb17a0b0cbdf752f776d2e68fa0faf87f5ba67 (diff) | |
download | FreeBSD-src-a9df32e6ddacac944e0ee28c6b36c4ff78df717b.zip FreeBSD-src-a9df32e6ddacac944e0ee28c6b36c4ff78df717b.tar.gz |
Rename isnumber() to cpio_isnumber() to avoid clashing with the
<ctype.h> library function of the same name.
Diffstat (limited to 'contrib/cpio/src')
-rw-r--r-- | contrib/cpio/src/userspec.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/contrib/cpio/src/userspec.c b/contrib/cpio/src/userspec.c index c426acd..7f7bed8 100644 --- a/contrib/cpio/src/userspec.c +++ b/contrib/cpio/src/userspec.c @@ -1,3 +1,5 @@ +/* $FreeBSD$ */ + /* userspec.c -- Parse a user and group string. Copyright (C) 1989, 1990, 1991, 1992, 2001, 2004 Free Software Foundation, Inc. @@ -72,7 +74,7 @@ extern struct group *getgrgid (gid_t gid); otherwise return 0. */ static int -isnumber (const char *str) +cpio_isnumber (const char *str) { for (; *str; str++) if (!isdigit (*str)) @@ -136,7 +138,7 @@ parse_user_spec (const char *spec_arg, uid_t *uid, gid_t *gid, if (pwd == NULL) { - if (!isnumber (u)) + if (!cpio_isnumber (u)) error_msg = _("invalid user"); else { @@ -182,7 +184,7 @@ parse_user_spec (const char *spec_arg, uid_t *uid, gid_t *gid, grp = getgrnam (g); if (grp == NULL) { - if (!isnumber (g)) + if (!cpio_isnumber (g)) error_msg = _("invalid group"); else *gid = atoi (g); |