From 08019e8a337c5e378ec9dfc70698adb73b9b7676 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 16 Jan 2002 23:53:10 +0000 Subject: Separate out get_user_home_dir() from get_user_home_service_dir(). Jeremy. (This used to be commit c1b97226db63daf64359e79083a4754e7c7f8054) --- source3/lib/substitute.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'source3/lib/substitute.c') diff --git a/source3/lib/substitute.c b/source3/lib/substitute.c index deef085c99..5a2bc1d890 100644 --- a/source3/lib/substitute.c +++ b/source3/lib/substitute.c @@ -97,10 +97,7 @@ static char *automount_path(const char *user_name) /* use the passwd entry as the default */ /* this will be the default if WITH_AUTOMOUNT is not used or fails */ - if (((pass = Get_Pwnam(user_name))!=NULL) && (pass->pw_dir != NULL)) - pstrcpy(server_path, pass->pw_dir ); - else - *server_path = '\0'; + pstrcpy(server_path, get_user_home_dir(user_name)); #if (defined(HAVE_NETGROUP) && defined (WITH_AUTOMOUNT)) @@ -117,7 +114,6 @@ static char *automount_path(const char *user_name) } } else { /* NIS key lookup failed: default to user home directory from password file */ - pstrcpy(server_path, get_user_home_dir(user_name)); DEBUG(5, ("NIS lookup failed. Using Home path from passwd file. Home path is: %s\n", server_path )); } } -- cgit