From add3d572d05951f6f5ac89044d449c4dbdc03308 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Wed, 24 Dec 2008 13:05:25 +0100 Subject: Remove unused function get_numlist() --- source3/lib/util.c | 51 --------------------------------------------------- 1 file changed, 51 deletions(-) (limited to 'source3/lib') diff --git a/source3/lib/util.c b/source3/lib/util.c index dd23d547b5..7053fdc266 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -491,57 +491,6 @@ bool add_gid_to_array_unique(TALLOC_CTX *mem_ctx, gid_t gid, return True; } -/**************************************************************************** - Like atoi but gets the value up to the separator character. -****************************************************************************/ - -static const char *Atoic(const char *p, int *n, const char *c) -{ - if (!isdigit((int)*p)) { - DEBUG(5, ("Atoic: malformed number\n")); - return NULL; - } - - (*n) = atoi(p); - - while ((*p) && isdigit((int)*p)) - p++; - - if (strchr_m(c, *p) == NULL) { - DEBUG(5, ("Atoic: no separator characters (%s) not found\n", c)); - return NULL; - } - - return p; -} - -/************************************************************************* - Reads a list of numbers. - *************************************************************************/ - -const char *get_numlist(const char *p, uint32 **num, int *count) -{ - int val; - - if (num == NULL || count == NULL) - return NULL; - - (*count) = 0; - (*num ) = NULL; - - while ((p = Atoic(p, &val, ":,")) != NULL && (*p) != ':') { - *num = SMB_REALLOC_ARRAY((*num), uint32, (*count)+1); - if (!(*num)) { - return NULL; - } - (*num)[(*count)] = val; - (*count)++; - p++; - } - - return p; -} - /******************************************************************* Check if a file exists - call vfs_file_exist for samba files. ********************************************************************/ -- cgit