/[cvs]/ccvs/src/commit.c
ViewVC logotype

Diff of /ccvs/src/commit.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.253 by dprice, Tue Aug 30 01:55:19 2005 UTC revision 1.254 by scjones, Fri Sep 2 21:51:08 2005 UTC
# Line 355  commit (int argc, char **argv) Line 355  commit (int argc, char **argv)
355      /* FIXME: Shouldn't this check be much more closely related to the      /* FIXME: Shouldn't this check be much more closely related to the
356         readonly user stuff (CVSROOT/readers, &c).  That is, why should         readonly user stuff (CVSROOT/readers, &c).  That is, why should
357         root be able to "cvs init", "cvs import", &c, but not "cvs ci"?  */         root be able to "cvs init", "cvs import", &c, but not "cvs ci"?  */
358      if (geteuid () == (uid_t) 0      /* Who we are on the client side doesn't affect logging.  */
359  #  ifdef CLIENT_SUPPORT      if (geteuid () == (uid_t) 0 && !current_parsed_root->isremote)
         /* Who we are on the client side doesn't affect logging.  */  
         && !current_parsed_root->isremote  
 #  endif  
         )  
360      {      {
361          struct passwd *pw;          struct passwd *pw;
362    
# Line 701  commit (int argc, char **argv) Line 697  commit (int argc, char **argv)
697      dellist (&mulist);      dellist (&mulist);
698    
699      /* see if we need to sleep before returning to avoid time-stamp races */      /* see if we need to sleep before returning to avoid time-stamp races */
700      if (      if (!server_active && last_register_time)
701  #ifdef SERVER_SUPPORT      {
702          /* But only sleep on the client.  */          sleep_past (last_register_time);
703          !server_active &&      }
 #endif  
         last_register_time  
        )  
             sleep_past (last_register_time);  
704    
705      return err;      return err;
706  }  }
# Line 1383  commit_fileproc (void *callerdat, struct Line 1375  commit_fileproc (void *callerdat, struct
1375      if (!got_message)      if (!got_message)
1376      {      {
1377          got_message = 1;          got_message = 1;
1378          if (          if (!server_active && use_editor)
 #ifdef SERVER_SUPPORT  
             !server_active &&  
 #endif  
             use_editor)  
1379              do_editor (finfo->update_dir, &saved_message,              do_editor (finfo->update_dir, &saved_message,
1380                         finfo->repository, ulist);                         finfo->repository, ulist);
1381          do_verify (&saved_message, finfo->repository, ulist);          do_verify (&saved_message, finfo->repository, ulist);
# Line 1671  commit_direntproc (void *callerdat, cons Line 1659  commit_direntproc (void *callerdat, cons
1659      /* get commit message */      /* get commit message */
1660      got_message = 1;      got_message = 1;
1661      real_repos = Name_Repository (dir, update_dir);      real_repos = Name_Repository (dir, update_dir);
1662      if (      if (!server_active && use_editor)
 #ifdef SERVER_SUPPORT  
         !server_active &&  
 #endif  
         use_editor)  
1663          do_editor (update_dir, &saved_message, real_repos, ulist);          do_editor (update_dir, &saved_message, real_repos, ulist);
1664      do_verify (&saved_message, real_repos, ulist);      do_verify (&saved_message, real_repos, ulist);
1665      free (real_repos);      free (real_repos);
# Line 2151  checkaddfile (const char *file, const ch Line 2135  checkaddfile (const char *file, const ch
2135          /* and lock it */          /* and lock it */
2136          if (lock_RCS (file, rcs, rev, repository))          if (lock_RCS (file, rcs, rev, repository))
2137          {          {
2138              error (0, 0, "cannot lock `%s'.", rcs->path);              error (0, 0, "cannot lock revision %s in `%s'.",
2139                       rev ? rev : tag ? tag : "HEAD", rcs->path);
2140              if (rev != NULL)              if (rev != NULL)
2141                  free (rev);                  free (rev);
2142              goto out;              goto out;
# Line 2214  checkaddfile (const char *file, const ch Line 2199  checkaddfile (const char *file, const ch
2199              /* and lock it once again. */              /* and lock it once again. */
2200              if (lock_RCS (file, rcs, NULL, repository))              if (lock_RCS (file, rcs, NULL, repository))
2201              {              {
2202                  error (0, 0, "cannot lock `%s'.", rcs->path);                  error (0, 0, "cannot lock initial revision in `%s'.",
2203                           rcs->path);
2204                  goto out;                  goto out;
2205              }              }
2206          }          }
# Line 2322  checkaddfile (const char *file, const ch Line 2308  checkaddfile (const char *file, const ch
2308              /* lock the branch. (stubbed branches need not be locked.)  */              /* lock the branch. (stubbed branches need not be locked.)  */
2309              if (lock_RCS (file, rcs, NULL, repository))              if (lock_RCS (file, rcs, NULL, repository))
2310              {              {
2311                  error (0, 0, "cannot lock `%s'.", rcs->path);                  error (0, 0, "cannot lock head revision in `%s'.", rcs->path);
2312                  goto out;                  goto out;
2313              }              }
2314          }          }

Legend:
Removed from v.1.253  
changed lines
  Added in v.1.254

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26