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

Diff for /src/usr.bin/at/at.c between version 1.17 and 1.18

version 1.17, 1999/12/15 05:33:06 version 1.18, 2000/01/21 04:22:54
Line 280 
Line 280 
                 panic("Cannot reopen atjob file");                  panic("Cannot reopen atjob file");
   
         /*          /*
          * Get the userid to mail to, first by trying getlogin(), which reads           * Get the userid to mail to, first by trying getlogin(), which asks
          * /etc/utmp, then from $LOGNAME or $USER, finally from getpwuid().           * the kernel, then from $LOGNAME or $USER, finally from getpwuid().
          */           */
         mailname = getlogin();          mailname = getlogin();
         if (mailname == NULL && (mailname = getenv("LOGNAME")) == NULL)          if (mailname == NULL && (mailname = getenv("LOGNAME")) == NULL)
Line 361 
Line 361 
          * Cd to the directory at the time and write out all the           * Cd to the directory at the time and write out all the
          * commands the user supplies from stdin.           * commands the user supplies from stdin.
          */           */
           if ((ap = cwdname()) == NULL)
                   perr("Cannot get current working directory");
         (void)fputs("cd ", fp);          (void)fputs("cd ", fp);
         for (ap = cwdname(); *ap != '\0'; ap++) {          for (; *ap != '\0'; ap++) {
                 if (*ap == '\n')                  if (*ap == '\n')
                         fprintf(fp, "\"\n\"");                          fprintf(fp, "\"\n\"");
                 else {                  else {

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18