fix an apparent merge error
authorBdale Garbee <bdale@gag.com>
Thu, 15 May 2008 06:50:33 +0000 (00:50 -0600)
committerBdale Garbee <bdale@gag.com>
Thu, 15 May 2008 06:50:33 +0000 (00:50 -0600)
sudo.c

diff --git a/sudo.c b/sudo.c
index f051d5ae9455ad766c4a7093f82ae67855074765..0f8e2deb79e832139b5b113a535d969b71438647 100644 (file)
--- a/sudo.c
+++ b/sudo.c
@@ -1243,34 +1243,6 @@ set_runaspw(user)
     return(TRUE);
 }
 
-/*
- * Get passwd entry for the user we are going to run commands as.
- * By default, this is "root".  Updates runas_pw as a side effect.
- */
-int
-set_runaspw(user)
-    char *user;
-{
-    if (runas_pw != NULL) {
-       if (user_runas != &def_runas_default)
-           return(TRUE);               /* don't override -u option */
-       efree(runas_pw);
-    }
-    if (*user == '#') {
-       runas_pw = sudo_getpwuid(atoi(user + 1));
-       if (runas_pw == NULL) {
-           runas_pw = emalloc(sizeof(struct passwd));
-           (void) memset((VOID *)runas_pw, 0, sizeof(struct passwd));
-           runas_pw->pw_uid = atoi(user + 1);
-       }
-    } else {
-       runas_pw = sudo_getpwnam(user);
-       if (runas_pw == NULL)
-           log_error(NO_MAIL|MSG_ONLY, "no passwd entry for %s!", user);
-    }
-    return(TRUE);
-}
-
 /*
  * Get passwd entry for the user we are going to authenticate as.
  * By default, this is the user invoking sudo.  In the most common