diff options
author | Jeremy Allison <jra@samba.org> | 2011-05-31 16:14:04 -0700 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2011-06-01 02:54:51 +0200 |
commit | 1cee71713f75dbee653ea86bd4e7c87efe677cf6 (patch) | |
tree | d55d8051935077eda22d05a4078a7097b27d05ae /source3/client | |
parent | 5abab13851ff2fc3a5792d08cc753c9b479c8cc1 (diff) | |
download | samba-1cee71713f75dbee653ea86bd4e7c87efe677cf6.tar.gz |
Change sys_getcd() to take no arguments and always return malloc'ed memory (or NULL).
Part of the efforts to remove PATH_MAX on modern systems.
Diffstat (limited to 'source3/client')
-rw-r--r-- | source3/client/client.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/client/client.c b/source3/client/client.c index 7cffddb76ca..f088c7c8158 100644 --- a/source3/client/client.c +++ b/source3/client/client.c @@ -3876,11 +3876,12 @@ static int cmd_lcd(void) buf, strerror(errno)); } } - d = TALLOC_ARRAY(ctx, char, PATH_MAX+1); + d = sys_getwd(); if (!d) { return 1; } - DEBUG(2,("the local directory is now %s\n",sys_getwd(d))); + DEBUG(2,("the local directory is now %s\n",d)); + SAFE_FREE(d); return 0; } |