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

Diff for /src/usr.bin/rcs/ci.c between version 1.188 and 1.189

version 1.188, 2006/09/27 06:26:35 version 1.189, 2006/11/09 21:47:52
Line 499 
Line 499 
         }          }
   
         /* If no log message specified, get it interactively. */          /* If no log message specified, get it interactively. */
         if (pb->flags & INTERACTIVE)          if (pb->flags & INTERACTIVE) {
                 pb->rcs_msg = checkin_getlogmsg(pb->frev, pb->newrev,                  if (pb->rcs_msg != NULL) {
                     pb->flags);                          fprintf(stderr,
                               "reuse log message of previous file? [yn](y): ");
                           if (rcs_yesno('y') != 'y') {
                                   xfree(pb->rcs_msg);
                                   pb->rcs_msg = NULL;
                           }
                   }
                   if (pb->rcs_msg == NULL)
                           pb->rcs_msg = checkin_getlogmsg(pb->frev, pb->newrev,
                               pb->flags);
           }
   
         if (rcs_lock_remove(pb->file, pb->username, pb->frev) < 0) {          if (rcs_lock_remove(pb->file, pb->username, pb->frev) < 0) {
                 if (rcs_errno != RCS_ERR_NOENT)                  if (rcs_errno != RCS_ERR_NOENT)
Line 551 
Line 561 
                 err(1, "%s", pb->filename);                  err(1, "%s", pb->filename);
   
         /* Strip all the write bits */          /* Strip all the write bits */
         pb->file->rf_mode = st.st_mode &          pb->file->rf_mode = st.st_mode & ~(S_IWUSR|S_IWGRP|S_IWOTH);
             (S_IXUSR|S_IXGRP|S_IXOTH|S_IRUSR|S_IRGRP|S_IROTH);  
   
         (void)close(workfile_fd);          (void)close(workfile_fd);
         (void)unlink(pb->filename);          (void)unlink(pb->filename);
Line 565 
Line 574 
             !(pb->flags & CI_DEFAULT))              !(pb->flags & CI_DEFAULT))
                 checkout_rev(pb->file, pb->newrev, pb->filename, pb->flags,                  checkout_rev(pb->file, pb->newrev, pb->filename, pb->flags,
                     pb->username, pb->author, NULL, NULL);                      pb->username, pb->author, NULL, NULL);
   
         if (pb->flags & INTERACTIVE) {  
                 xfree(pb->rcs_msg);  
                 pb->rcs_msg = NULL;  
         }  
   
 out:  out:
         return (0);          return (0);
   
Line 676 
Line 679 
                 err(1, "%s", pb->filename);                  err(1, "%s", pb->filename);
   
         /* Strip all the write bits */          /* Strip all the write bits */
         pb->file->rf_mode = st.st_mode &          pb->file->rf_mode = st.st_mode & ~(S_IWUSR|S_IWGRP|S_IWOTH);
             (S_IXUSR|S_IXGRP|S_IXOTH|S_IRUSR|S_IRGRP|S_IROTH);  
   
         (void)close(workfile_fd);          (void)close(workfile_fd);
         (void)unlink(pb->filename);          (void)unlink(pb->filename);

Legend:
Removed from v.1.188  
changed lines
  Added in v.1.189