mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
param: remove duplicate lp_int function
Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <abartlet@samba.org>
This commit is contained in:
parent
f6697ef8da
commit
45184c9758
@ -327,10 +327,10 @@ const char *lpcfg_get_parametric(struct loadparm_context *lp_ctx,
|
||||
/**
|
||||
* convenience routine to return int parameters.
|
||||
*/
|
||||
static int lp_int(const char *s)
|
||||
int lp_int(const char *s)
|
||||
{
|
||||
|
||||
if (!s) {
|
||||
if (!s || !*s) {
|
||||
DEBUG(0,("lp_int(%s): is called with NULL!\n",s));
|
||||
return -1;
|
||||
}
|
||||
|
@ -1252,20 +1252,6 @@ static struct parmlist_entry *get_parametrics(int snum, const char *type,
|
||||
#define MISSING_PARAMETER(name) \
|
||||
DEBUG(0, ("%s(): value is NULL or empty!\n", #name))
|
||||
|
||||
/*******************************************************************
|
||||
convenience routine to return int parameters.
|
||||
********************************************************************/
|
||||
static int lp_int(const char *s)
|
||||
{
|
||||
|
||||
if (!s || !*s) {
|
||||
MISSING_PARAMETER(lp_int);
|
||||
return (-1);
|
||||
}
|
||||
|
||||
return (int)strtol(s, NULL, 0);
|
||||
}
|
||||
|
||||
/*******************************************************************
|
||||
convenience routine to return unsigned long parameters.
|
||||
********************************************************************/
|
||||
|
Loading…
Reference in New Issue
Block a user