[BACK]Return to popen.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / mail

Diff for /src/usr.bin/mail/popen.c between version 1.30 and 1.31

version 1.30, 2001/11/21 20:41:55 version 1.31, 2001/11/23 00:03:24
Line 128 
Line 128 
                 fd1 = -1;                  fd1 = -1;
         }          }
         sigemptyset(&nset);          sigemptyset(&nset);
         /*          pid = start_command(value("SHELL"), &nset, fd0, fd1, "-c", cmd, NULL);
          * If cmd contains meta chars wrap it in a shell.  
          */  
         if (strpbrk(cmd, "$&*(){}[]'\";\\|?<>~`"))  
                 pid = start_command(value("SHELL"), &nset, fd0, fd1,  
                     "-c", cmd, NULL);  
         else  
                 pid = start_command(cmd, &nset, fd0, fd1, NULL);  
         if (pid < 0) {          if (pid < 0) {
                 (void)close(p[READ]);                  (void)close(p[READ]);
                 (void)close(p[WRITE]);                  (void)close(p[WRITE]);
Line 450 
Line 443 
                             stderr);                              stderr);
                         return(-1);                          return(-1);
                 }                  }
                 (void)kill(lock_pid, SIGTERM);  
                 (void)Pclose(lockfp);                  (void)Pclose(lockfp);
                 lockfp = NULL;                  lockfp = NULL;
         } else if (action == 1) {          } else if (action == 1) {

Legend:
Removed from v.1.30  
changed lines
  Added in v.1.31