summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorMartin Pool <mbp@samba.org>2001-11-20 06:38:09 +0000
committerMartin Pool <mbp@samba.org>2001-11-20 06:38:09 +0000
commit5b1fb34731b3bc8331f99ae4e193b7c078ee9f7a (patch)
tree095766014748cff94fb44348ad565ddab0bfd542 /source3/utils
parent4950e6feb69ed73663faf2977520e90d97bbce03 (diff)
downloadsamba-5b1fb34731b3bc8331f99ae4e193b7c078ee9f7a.tar.gz
samba-5b1fb34731b3bc8331f99ae4e193b7c078ee9f7a.tar.bz2
samba-5b1fb34731b3bc8331f99ae4e193b7c078ee9f7a.zip
Rename xmalloc, xmemdup, xstrdup to smb_$1 to avoid conflicts with the
versions defined by libreadline on SCO (!). (This used to be commit 32480d7aff21ce1c14991e242aaf8a4e14ec6f2a)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/smbpasswd.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source3/utils/smbpasswd.c b/source3/utils/smbpasswd.c
index ea8fffc295..b60f919e79 100644
--- a/source3/utils/smbpasswd.c
+++ b/source3/utils/smbpasswd.c
@@ -458,7 +458,7 @@ static char *get_pass( char *prompt, BOOL stdin_get)
} else {
p = getpass(prompt);
}
- return xstrdup(p);
+ return smb_xstrdup(p);
}
/*************************************************************
@@ -685,7 +685,7 @@ static int process_root(int argc, char *argv[])
if (got_username || got_pass)
usage();
fstrcpy(user_name, argv[0]);
- new_passwd = xstrdup(argv[1]);
+ new_passwd = smb_xstrdup(argv[1]);
break;
default:
usage();
@@ -715,7 +715,7 @@ static int process_root(int argc, char *argv[])
if (local_flags & LOCAL_ADD_USER) {
SAFE_FREE(new_passwd);
- new_passwd = xstrdup(user_name);
+ new_passwd = smb_xstrdup(user_name);
strlower(new_passwd);
}
@@ -793,9 +793,9 @@ static int process_root(int argc, char *argv[])
}
-/*************************************************************
-handle password changing for non-root
-*************************************************************/
+/**
+ handle password changing for non-root
+**/
static int process_nonroot(int argc, char *argv[])
{
struct passwd *pwd = NULL;
@@ -842,9 +842,9 @@ static int process_nonroot(int argc, char *argv[])
if (!user_name) {
pwd = sys_getpwuid(getuid());
if (pwd) {
- user_name = xstrdup(pwd->pw_name);
+ user_name = smb_xstrdup(pwd->pw_name);
} else {
- fprintf(stderr,"you don't exist - go away\n");
+ fprintf(stderr, "smbpasswd: you don't exist - go away\n");
exit(1);
}
}