diff options
author | Andrew Bartlett <abartlet@samba.org> | 2002-06-15 13:05:37 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2002-06-15 13:05:37 +0000 |
commit | 09754ec797c4232d2016c7eff2e74044f28ebb7c (patch) | |
tree | 8af339b1235f3e369f671d7b7ee1d27e53c5308d /source/param/loadparm.c | |
parent | 957c865cee7f799145f9f1d30dfd0d0a25d826cf (diff) | |
download | samba-09754ec797c4232d2016c7eff2e74044f28ebb7c.tar.gz samba-09754ec797c4232d2016c7eff2e74044f28ebb7c.tar.xz samba-09754ec797c4232d2016c7eff2e74044f28ebb7c.zip |
Simplify this code further. Just substitute %H, and let the normal code
paths handle the rest later.
Andrew Bartlett
Diffstat (limited to 'source/param/loadparm.c')
-rw-r--r-- | source/param/loadparm.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/source/param/loadparm.c b/source/param/loadparm.c index 3c0820491d4..5be1fb27628 100644 --- a/source/param/loadparm.c +++ b/source/param/loadparm.c @@ -1902,8 +1902,7 @@ BOOL lp_add_home(const char *pszHomename, int iDefaultService, pstrcpy(newHomedir, pszHomedir); } else { pstrcpy(newHomedir, lp_pathname(iDefaultService)); - standard_sub_home(iDefaultService, pszHomename, user, - pszHomedir, newHomedir); + string_sub(newHomedir,"%H", pszHomedir, sizeof(newHomedir)); } string_set(&ServicePtrs[i]->szPath, newHomedir); @@ -1912,7 +1911,7 @@ BOOL lp_add_home(const char *pszHomename, int iDefaultService, { pstring comment; slprintf(comment, sizeof(comment) - 1, - "Home directory of %s", pszHomename); + "Home directory of %s", user); string_set(&ServicePtrs[i]->comment, comment); } ServicePtrs[i]->bAvailable = sDefault.bAvailable; @@ -1921,7 +1920,7 @@ BOOL lp_add_home(const char *pszHomename, int iDefaultService, DEBUG(3, ("adding home's share [%s] for user %s at %s\n", pszHomename, user, newHomedir)); - + return (True); } |