* krlogind.c (doit): Change 0 to (char*)NULL in execl* calls. Patch provided
authorKen Raeburn <raeburn@mit.edu>
Wed, 6 Apr 2005 00:13:02 +0000 (00:13 +0000)
committerKen Raeburn <raeburn@mit.edu>
Wed, 6 Apr 2005 00:13:02 +0000 (00:13 +0000)
by Michael Calmer.
* krshd.c (doit): Likewise.
* login.c (main): Likewise.

ticket: 3000
status: open

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@17165 dc483132-0cff-0310-8789-dd5450dbe970

src/appl/bsd/ChangeLog
src/appl/bsd/krlogind.c
src/appl/bsd/krshd.c
src/appl/bsd/login.c

index fcf95173b04d5ffd11c302dae985c9be7adbf570..c5e5bc879f7ef054a848e1211a753366c4da5931 100644 (file)
@@ -1,3 +1,10 @@
+2005-04-05  Ken Raeburn  <raeburn@mit.edu>
+
+       * krlogind.c (doit): Change 0 to (char*)NULL in execl* calls.
+       Patch provided by Michael Calmer.
+       * krshd.c (doit): Likewise.
+       * login.c (main): Likewise.
+
 2004-10-01  Ken Raeburn  <raeburn@mit.edu>
 
        * kcmd.c (kcmd_connect): Set *addrfamilyp with the address family
index d2979e1416331f977b3958287b13d708a2df1a86..02bed8e370f137d5f3643d1b1d8f49f564975df0 100644 (file)
@@ -833,12 +833,12 @@ void doit(f, fromp)
         fatalperror(f, "failed make_sane_hostname");
     if (passwd_req)
         execl(login_program, "login", "-p", "-h", rhost_sane,
-          lusername, 0);
+          lusername, (char *)NULL);
     else
         execl(login_program, "login", "-p", "-h", rhost_sane,
-             "-f", lusername, 0);
+             "-f", lusername, (char *)NULL);
 #else /* USE_LOGIN_F */
-       execl(login_program, "login", "-r", rhost_sane, 0);
+       execl(login_program, "login", "-r", rhost_sane, (char *)NULL);
 #endif /* USE_LOGIN_F */
        syslog(LOG_ERR, "failed exec of %s: %s",
               login_program, error_message(errno));
index 9fde43d6eddea24b48428c5f4abb5ec9a1ee51d9..808adf5d538006db9453c842cdd75b88c2f16024 100644 (file)
@@ -1521,10 +1521,10 @@ void doit(f, fromp)
       cp = pwd->pw_shell;
     
     if (do_encrypt && !strncmp(cmdbuf, "-x ", 3)) {
-       execl(pwd->pw_shell, cp, "-c", (char *)cmdbuf + 3, 0);
+       execl(pwd->pw_shell, cp, "-c", (char *)cmdbuf + 3, (char *)NULL);
     }
     else {
-       execl(pwd->pw_shell, cp, "-c", cmdbuf, 0);
+       execl(pwd->pw_shell, cp, "-c", cmdbuf, (char *)NULL);
     }
     perror(pwd->pw_shell);
     perror(cp);
index 6282a42f073f2b621b4cf2e32ea70c8ec26af5b9..b49bababb7262f144a7eeeebfbb367c174dc40a9 100644 (file)
@@ -1861,7 +1861,7 @@ int main(argc, argv)
     (void) strncpy(tbuf+1, p?(p+1):pwd->pw_shell, sizeof(tbuf) - 1);
     tbuf[sizeof(tbuf) - 1] = '\0';
 
-    execlp(pwd->pw_shell, tbuf, 0);
+    execlp(pwd->pw_shell, tbuf, (char *)NULL);
     fprintf(stderr, "login: no shell: ");
     perror(pwd->pw_shell);
     exit(0);