CVS update: /ccvs/src/

[email protected] 24 May 2005 20:59:04 -0000
Newsgroups gmane.comp.version-control.cvs.cvs
Message-ID <[email protected]>
User: dprice  
Date: 05/05/24 13:59:04

Modified:
 /ccvs/src/
  ChangeLog, client.c, entries.c, filesubr.c, hardlink.c, ignore.c, import.c,
  lock.c, logmsg.c, mkmodules.c, rcs.c, rcscmds.c, server.c, subr.c, update.c,
  vers_ts.c

Log:
 * client.c, entries.c, filesubr.c, hardlink.c, ignore.c, import.c,
 lock.c, logmsg.c, mkmodules.c, rcs.c, rcscmds.c, server.c, subr.c,
 update.c, vers_ts.c: s/CVS_STAT/stat/ & s/CVS_LSTAT/lstat/.

File Changes:

Directory: /ccvs/src/
=====================

File [changed]: ChangeLog
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/ChangeLog?r1=1.3196&r2=1.3197
Delta lines:  +6 -0
-------------------
--- ChangeLog	23 May 2005 22:56:41 -0000	1.3196
+++ ChangeLog	24 May 2005 20:59:01 -0000	1.3197
@@ -1,3 +1,9 @@
+2005-05-24  Derek Price  <[email protected]>
+
+	* client.c, entries.c, filesubr.c, hardlink.c, ignore.c, import.c,
+	lock.c, logmsg.c, mkmodules.c, rcs.c, rcscmds.c, server.c, subr.c,
+	update.c, vers_ts.c: s/CVS_STAT/stat/ & s/CVS_LSTAT/lstat/.
+
 2005-05-23  Derek Price  <[email protected]>
 
 	* filesubr.c (xresolvepath): Move to...

File [changed]: client.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/client.c?r1=1.423&r2=1.424
Delta lines:  +2 -2
-------------------
--- client.c	22 Mar 2005 13:19:57 -0000	1.423
+++ client.c	24 May 2005 20:59:01 -0000	1.424
@@ -4217,7 +4217,7 @@
     TRACE (TRACE_FUNCTION, "Sending file `%s' to server", file);
 
     /* Don't think we can assume fstat exists.  */
-    if (CVS_STAT (file, &sb) < 0)
+    if (stat (file, &sb) < 0)
 	error (1, errno, "reading %s", short_pathname);
 
     mode_string = mode_to_string (sb.st_mode);
@@ -4988,7 +4988,7 @@
 	    char *rcsdate;
 	    char netdate[MAXDATELEN];
 
-	    if (CVS_STAT (vfile, &sb) < 0)
+	    if (stat (vfile, &sb) < 0)
 		error (1, errno, "cannot stat %s", fullname);
 	    rcsdate = date_from_time_t (sb.st_mtime);
 	    date_to_internet (netdate, rcsdate);

File [changed]: entries.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/entries.c?r1=1.64&r2=1.65
Delta lines:  +1 -1
-------------------
--- entries.c	16 Mar 2005 22:00:49 -0000	1.64
+++ entries.c	24 May 2005 20:59:01 -0000	1.65
@@ -353,7 +353,7 @@
 	 */
 	{
 	    struct stat sb;
-	    if (strlen (ts) > 30 && CVS_STAT (user, &sb) == 0)
+	    if (strlen (ts) > 30 && stat (user, &sb) == 0)
 	    {
 		char *c = ctime (&sb.st_mtime);
 		/* Fix non-standard format.  */

File [changed]: filesubr.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/filesubr.c?r1=1.98&r2=1.99
Delta lines:  +10 -10
---------------------
--- filesubr.c	23 May 2005 22:56:41 -0000	1.98
+++ filesubr.c	24 May 2005 20:59:01 -0000	1.99
@@ -52,7 +52,7 @@
     if (isdevice (from))
     {
 #if defined(HAVE_MKNOD) && defined(HAVE_STRUCT_STAT_ST_RDEV)
-	if( CVS_STAT( from, &sb ) < 0 )
+	if (stat (from, &sb) < 0)
 	    error (1, errno, "cannot stat %s", from);
 	mknod (to, sb.st_mode, sb.st_rdev);
 #else
@@ -120,7 +120,7 @@
 {
     struct stat sb;
 
-    if (CVS_STAT (file, &sb) < 0)
+    if (stat (file, &sb) < 0)
 	return false;
     return S_ISDIR (sb.st_mode);
 }
@@ -138,7 +138,7 @@
 #ifdef S_ISLNK
     struct stat sb;
 
-    if ((CVS_LSTAT (file, &sb) >= 0) && S_ISLNK (sb.st_mode))
+    if ((lstat (file, &sb) >= 0) && S_ISLNK (sb.st_mode))
 	retsize = sb.st_size;
 #endif
     return retsize;
@@ -155,7 +155,7 @@
 {
     struct stat sb;
 
-    if (CVS_LSTAT (file, &sb) < 0)
+    if (lstat (file, &sb) < 0)
 	return false;
 #ifdef S_ISBLK
     if (S_ISBLK (sb.st_mode))
@@ -218,7 +218,7 @@
     int omask = 0;
     int uid, mask;
     
-    if (CVS_STAT (file, &sb)== -1)
+    if (stat (file, &sb)== -1)
 	return false;
     if (mode == F_OK)
 	return true;
@@ -272,7 +272,7 @@
 {
     struct stat sb;
 
-    if( CVS_STAT( name, &sb ) == 0 && ( !S_ISDIR( sb.st_mode ) ) )
+    if (stat (name, &sb) == 0 && (!S_ISDIR (sb.st_mode)))
 	    error (0, 0, "%s already exists but is not a directory", name);
     if (!noexec && mkdir (name, 0777) < 0)
 	error (1, errno, "cannot make directory %s", name);
@@ -341,7 +341,7 @@
 	return;
 #endif /* PRESERVE_PERMISSIONS_SUPPORT */
 
-    if( CVS_STAT( fname, &sb ) < 0 )
+    if (stat (fname, &sb) < 0)
     {
 	if (!noexec)
 	    error (0, errno, "cannot stat %s", fname);
@@ -430,7 +430,7 @@
        call to stat() and the call to unlink(), we'll still corrupt
        the filesystem.  Where is the Unix Haters Handbook when you need
        it?  */
-    if( CVS_STAT( f, &sb ) < 0 )
+    if (stat (f, &sb) < 0)
     {
 	if (existence_error (errno))
 	{
@@ -572,9 +572,9 @@
     int fd1, fd2;
     int ret;
 
-    if (CVS_LSTAT (file1, &sb1) < 0)
+    if (lstat (file1, &sb1) < 0)
 	error (1, errno, "cannot lstat %s", file1);
-    if (CVS_LSTAT (file2, &sb2) < 0)
+    if (lstat (file2, &sb2) < 0)
 	error (1, errno, "cannot lstat %s", file2);
 
     /* If FILE1 and FILE2 are not the same file type, they are unequal. */

File [changed]: hardlink.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/hardlink.c?r1=1.15&r2=1.16
Delta lines:  +2 -2
-------------------
--- hardlink.c	10 Mar 2005 20:44:28 -0000	1.15
+++ hardlink.c	24 May 2005 20:59:01 -0000	1.16
@@ -73,7 +73,7 @@
     else
 	file = filepath;
 
-    if (CVS_STAT (file, &sb) < 0)
+    if (stat (file, &sb) < 0)
     {
 	if (existence_error (errno))
 	{
@@ -194,7 +194,7 @@
        linkage for a file would always fail. */
     (void) lookup_file_by_inode (path);
 
-    if (CVS_STAT (path, &sb) < 0)
+    if (stat (path, &sb) < 0)
 	error (1, errno, "cannot stat %s", file);
     /* inodestr contains the hexadecimal representation of an
        inode. */

File [changed]: ignore.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/ignore.c?r1=1.53&r2=1.54
Delta lines:  +1 -1
-------------------
--- ignore.c	22 Mar 2005 13:19:57 -0000	1.53
+++ ignore.c	24 May 2005 20:59:01 -0000	1.54
@@ -433,7 +433,7 @@
 #ifdef DT_DIR
 	    dp->d_type != DT_UNKNOWN ||
 #endif
-	    CVS_LSTAT (file, &sb) != -1)
+	    lstat (file, &sb) != -1)
 	{
 
 	    if (

File [changed]: import.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/import.c?r1=1.169&r2=1.170
Delta lines:  +1 -1
-------------------
--- import.c	10 Mar 2005 20:44:28 -0000	1.169
+++ import.c	24 May 2005 20:59:01 -0000	1.170
@@ -1145,7 +1145,7 @@
        `cannot lstat'.  I don't see a way around this, since we must
        stat the file before opening it. -twp */
 
-    if (CVS_LSTAT (userfile, &sb) < 0)
+    if (lstat (userfile, &sb) < 0)
     {
 	/* not fatal, continue import */
 	if (add_logfp != NULL)

File [changed]: lock.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/lock.c?r1=1.116&r2=1.117
Delta lines:  +5 -5
-------------------
--- lock.c	2 May 2005 19:49:36 -0000	1.116
+++ lock.c	24 May 2005 20:59:01 -0000	1.117
@@ -210,7 +210,7 @@
 
 	/* In the common case, where the directory already exists, let's
 	   keep it to one system call.  */
-	if (CVS_STAT (retval, &sb) < 0)
+	if (stat (retval, &sb) < 0)
 	{
 	    /* If we need to be creating more than one directory, we'll
 	       get the existence_error here.  */
@@ -241,7 +241,7 @@
 	   because the locks will generally be removed by the process
 	   which created them.  */
 
-	if (CVS_STAT (config->lock_dir, &sb) < 0)
+	if (stat (config->lock_dir, &sb) < 0)
 	    error (1, errno, "cannot stat %s", config->lock_dir);
 	new_mode = sb.st_mode;
 	save_umask = umask (0000);
@@ -264,7 +264,7 @@
 			error (1, errno, "cannot make directory %s", retval);
 		    else
 		    {
-			if (CVS_STAT (retval, &sb) < 0)
+			if (stat (retval, &sb) < 0)
 			    error (1, errno, "cannot stat %s", retval);
 			new_mode = sb.st_mode;
 		    }
@@ -621,7 +621,7 @@
 		    continue;
 
 		line = Xasprintf ("%s/%s", lockdir, dp->d_name);
-		if (CVS_STAT (line, &sb) != -1)
+		if (stat (line, &sb) != -1)
 		{
 #ifdef CVS_FUDGELOCKS
 		    /*
@@ -1063,7 +1063,7 @@
 	/* Find out who owns the lock.  If the lock directory is
 	   non-existent, re-try the loop since someone probably just
 	   removed it (thus releasing the lock).  */
-	if (CVS_STAT (masterlock, &sb) < 0)
+	if (stat (masterlock, &sb) < 0)
 	{
 	    if (existence_error (errno))
 		continue;

File [changed]: logmsg.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/logmsg.c?r1=1.95&r2=1.96
Delta lines:  +4 -4
-------------------
--- logmsg.c	22 Mar 2005 13:19:57 -0000	1.95
+++ logmsg.c	24 May 2005 20:59:01 -0000	1.96
@@ -284,7 +284,7 @@
     /* finish off the temp file */
     if (fclose (fp) == EOF)
         error (1, errno, "%s", fname);
-    if ( CVS_STAT (fname, &pre_stbuf) == -1)
+    if (stat (fname, &pre_stbuf) == -1)
 	pre_stbuf.st_mtime = 0;
 
     /* run the editor */
@@ -301,7 +301,7 @@
     if (*messagep)
 	free (*messagep);
 
-    if ( CVS_STAT (fname, &post_stbuf) != 0)
+    if (stat (fname, &post_stbuf) != 0)
 	    error (1, errno, "cannot find size of temp file %s", fname);
 
     if (post_stbuf.st_size == 0)
@@ -446,7 +446,7 @@
     if (config->RereadLogAfterVerify == LOGMSG_REREAD_ALWAYS ||
 	config->RereadLogAfterVerify == LOGMSG_REREAD_STAT)
     {
-	if(CVS_STAT (data.fname, &post_stbuf) != 0)
+	if(stat (data.fname, &post_stbuf) != 0)
 	    error (1, errno, "cannot find size of temp file %s", data.fname);
     }
 
@@ -898,7 +898,7 @@
 	if (config->RereadLogAfterVerify == LOGMSG_REREAD_STAT)
 	{
 	    /* Remember the status of the temp file for later */
-	    if (CVS_STAT (vpd->fname, &(vpd->pre_stbuf)) != 0)
+	    if (stat (vpd->fname, &(vpd->pre_stbuf)) != 0)
 		error (1, errno, "cannot stat temp file %s", vpd->fname);
 
 	    /*

File [changed]: mkmodules.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/mkmodules.c?r1=1.93&r2=1.94
Delta lines:  +1 -1
-------------------
--- mkmodules.c	25 Apr 2005 20:18:08 -0000	1.93
+++ mkmodules.c	24 May 2005 20:59:01 -0000	1.94
@@ -1106,7 +1106,7 @@
     /* Set "x" bits if set in original. */
     rcs = Xasprintf ("%s%s", real, RCSEXT);
     statbuf.st_mode = 0; /* in case rcs file doesn't exist, but it should... */
-    if (CVS_STAT (rcs, &statbuf) < 0
+    if (stat (rcs, &statbuf) < 0
 	&& !existence_error (errno))
 	error (0, errno, "cannot stat %s", rcs);
     free (rcs);

File [changed]: rcs.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/rcs.c?r1=1.346&r2=1.347
Delta lines:  +5 -5
-------------------
--- rcs.c	20 Apr 2005 20:55:02 -0000	1.346
+++ rcs.c	24 May 2005 20:59:01 -0000	1.347
@@ -4264,7 +4264,7 @@
 	{
 	    /* If RCS_deltas didn't close the file, we could use fstat
 	       here too.  Probably should change it thusly....  */
-	    if (CVS_STAT (rcs->path, &sb) < 0)
+	    if (stat (rcs->path, &sb) < 0)
 		error (1, errno, "cannot stat %s", rcs->path);
 	    rcsbufp = NULL;
 	}
@@ -5070,7 +5070,7 @@
     if (flags & RCS_FLAGS_MODTIME)
     {
 	struct stat ws;
-	if (CVS_STAT (workfile, &ws) < 0)
+	if (stat (workfile, &ws) < 0)
 	{
 	    error (1, errno, "cannot stat %s", workfile);
 	}
@@ -5113,7 +5113,7 @@
 
 	delta->other_delta = getlist();
 
-	if (CVS_LSTAT (workfile, &sb) < 0)
+	if (lstat (workfile, &sb) < 0)
 	    error (1, errno, "cannot lstat %s", workfile);
 
 	if (S_ISLNK (sb.st_mode))
@@ -8416,7 +8416,7 @@
        file.  (Really, this is a lie -- if this is a new file,
        RCS_checkin uses the permissions from the working copy.  For
        actually creating the file, we use 0444 as a safe default mode.) */
-    if( CVS_STAT( rcsfile, &rstat ) < 0 )
+    if (stat (rcsfile, &rstat) < 0)
     {
 	if (existence_error (errno))
 	    rstat.st_mode = S_IRUSR | S_IRGRP | S_IROTH;
@@ -8630,7 +8630,7 @@
 	if (strcmp(DEVNULL, path))
 	{
 	    const char *file = last_component (path);
-	    if (CVS_STAT (file, &sb) < 0)
+	    if (stat (file, &sb) < 0)
 		/* Assume that if the stat fails,then the later read for the
 		 * diff will too.
 		 */

File [changed]: rcscmds.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/rcscmds.c?r1=1.68&r2=1.69
Delta lines:  +2 -2
-------------------
--- rcscmds.c	17 Mar 2005 17:15:19 -0000	1.68
+++ rcscmds.c	24 May 2005 20:59:02 -0000	1.69
@@ -552,9 +552,9 @@
     {
 	struct stat sb1, sb2;
 
-	if (CVS_LSTAT (file1, &sb1) < 0)
+	if (lstat (file1, &sb1) < 0)
 	    error (1, errno, "cannot get file information for %s", file1);
-	if (CVS_LSTAT (file2, &sb2) < 0)
+	if (lstat (file2, &sb2) < 0)
 	    error (1, errno, "cannot get file information for %s", file2);
 
 	if (!S_ISREG (sb1.st_mode) && !S_ISDIR (sb1.st_mode))

File [changed]: server.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/server.c?r1=1.429&r2=1.430
Delta lines:  +2 -2
-------------------
--- server.c	23 May 2005 22:56:41 -0000	1.429
+++ server.c	24 May 2005 20:59:02 -0000	1.430
@@ -4373,7 +4373,7 @@
 	struct stat sb;
 	char *mode_string;
 
-	if ( CVS_STAT (file, &sb) < 0)
+	if (stat (file, &sb) < 0)
 	{
 	    /* Not clear to me why the file would fail to exist, but it
 	       was happening somewhere in the testsuite.  */
@@ -4923,7 +4923,7 @@
 	{
 	    struct stat sb;
 
-	    if ( CVS_STAT (finfo->file, &sb) < 0)
+	    if (stat (finfo->file, &sb) < 0)
 	    {
 		if (existence_error (errno))
 		{

File [changed]: subr.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/subr.c?r1=1.141&r2=1.142
Delta lines:  +1 -1
-------------------
--- subr.c	23 May 2005 22:56:42 -0000	1.141
+++ subr.c	24 May 2005 20:59:02 -0000	1.142
@@ -692,7 +692,7 @@
 	   be of arbitrary size, so I think we better do all that
 	   extra allocation.  */
 
-	if (CVS_STAT (name, &s) < 0)
+	if (stat (name, &s) < 0)
 	    error (1, errno, "can't stat %s", fullname);
 
 	/* Convert from signed to unsigned.  */

File [changed]: update.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/update.c?r1=1.252&r2=1.253
Delta lines:  +7 -7
-------------------
--- update.c	17 Mar 2005 17:15:19 -0000	1.252
+++ update.c	24 May 2005 20:59:02 -0000	1.253
@@ -1318,7 +1318,7 @@
 		   That would also fix the kludge with noexec, above, which
 		   is here only because noexec doesn't write srcfile->path
 		   for us to stat.  */
-		if( CVS_STAT( vers_ts->srcfile->path, &sb ) < 0 )
+		if (stat (vers_ts->srcfile->path, &sb) < 0)
 		{
 #if defined (SERVER_SUPPORT) || defined (CLIENT_SUPPORT)
 		    buf_free (revbuf);
@@ -1719,9 +1719,9 @@
 	struct stat file2_info;
 
 	/* Check to make sure the patch is really shorter */
-	if (CVS_STAT (file2, &file2_info) < 0)
+	if (stat (file2, &file2_info) < 0)
 	    error (1, errno, "could not stat %s", file2);
-	if (CVS_STAT (finfo->file, file_info) < 0)
+	if (stat (finfo->file, file_info) < 0)
 	    error (1, errno, "could not stat %s", finfo->file);
 	if (file2_info.st_size <= file_info->st_size)
 	    fail = 1;
@@ -1756,7 +1756,7 @@
 	/* Stat the original RCS file, and then adjust it the way
 	   that RCS_checkout would.  FIXME: This is an abstraction
 	   violation.  */
-	if (CVS_STAT (vers_ts->srcfile->path, file_info) < 0)
+	if (stat (vers_ts->srcfile->path, file_info) < 0)
 	    error (1, errno, "could not stat %s", vers_ts->srcfile->path);
 	if (chmod (finfo->file,
 		   file_info->st_mode & ~(S_IWRITE | S_IWGRP | S_IWOTH))
@@ -1777,7 +1777,7 @@
 		  xvers_ts->ts_user, xvers_ts->options,
 		  xvers_ts->tag, xvers_ts->date, NULL);
 
-	if (CVS_STAT (finfo->file, file_info) < 0)
+	if (stat (finfo->file, file_info) < 0)
 	    error (1, errno, "could not stat %s", finfo->file);
 
 	/* If this is really Update and not Checkout, record history.  */
@@ -2683,7 +2683,7 @@
 	else
 	{
 # ifdef HAVE_STRUCT_STAT_ST_RDEV
-	    if (CVS_LSTAT (finfo->file, &sb) < 0)
+	    if (lstat (finfo->file, &sb) < 0)
 		error (1, errno, "could not get file information for %s",
 		       finfo->file);
 	    rev1_uid = sb.st_uid;
@@ -2763,7 +2763,7 @@
 	else
 	{
 # ifdef HAVE_STRUCT_STAT_ST_RDEV
-	    if (CVS_LSTAT (finfo->file, &sb) < 0)
+	    if (lstat (finfo->file, &sb) < 0)
 		error (1, errno, "could not get file information for %s",
 		       finfo->file);
 	    rev2_uid = sb.st_uid;

File [changed]: vers_ts.c
Url: https://ccvs.cvshome.org/source/browse/ccvs/src/vers_ts.c?r1=1.62&r2=1.63
Delta lines:  +3 -3
-------------------
--- vers_ts.c	17 Mar 2005 17:15:20 -0000	1.62
+++ vers_ts.c	24 May 2005 20:59:02 -0000	1.63
@@ -288,7 +288,7 @@
     struct stat sb;
     char *cp;
 
-    if (CVS_LSTAT (file, &sb) < 0)
+    if (lstat (file, &sb) < 0)
     {
 	if (! existence_error (errno))
 	    error (1, errno, "cannot stat temp file");
@@ -386,7 +386,7 @@
     struct stat sb;
     time_t mtime = 0L;
 
-    if (!CVS_LSTAT (file, &sb))
+    if (!lstat (file, &sb))
     {
 	mtime = sb.st_mtime;
     }
@@ -394,7 +394,7 @@
     /* If it's a symlink, return whichever is the newest mtime of
        the link and its target, for safety.
     */
-    if (!CVS_STAT (file, &sb))
+    if (!stat (file, &sb))
     {
         if (mtime < sb.st_mtime)
 	    mtime = sb.st_mtime;