Hi, On Fri, Jul 30, 2004 at 01:12:13AM -0700, Paul Eggert wrote: > I installed this patch to use bool (and size_t) when possible, instead > of int. I don't think it fixes any bugs.
I'm afraid it introduces new bugs: [...] > /* Set the timestamps of file TO to match those of file FROM. > - Return 0 if successful, 1 if not. */ > + Return true if successful. */ > > -static int > +static bool > change_timestamps (const char *from, const char *to) > { > struct stat stb; > @@ -554,7 +546,7 @@ change_timestamps (const char *from, con > if (stat (from, &stb)) > { > error (0, errno, _("cannot obtain time stamps for %s"), quote (from)); > - return 1; > + return true; > } > > timespec[0].tv_sec = stb.st_atime; > @@ -564,9 +556,9 @@ change_timestamps (const char *from, con > if (utimens (to, timespec)) > { > error (0, errno, _("cannot set time stamps for %s"), quote (to)); > - return 1; > + return true; > } > - return 0; > + return false; > } > I had to apply attached patch to make "install -p" work again. -- ldv
2004-08-10 Dmitry V. Levin <[EMAIL PROTECTED]> * src/install.c (change_timestamps): Fix int->bool conversion bugs introduced at 2004-07-29. --- coreutils-200408100654.orig/src/install.c 2004-08-03 00:14:39 +0400 +++ coreutils-200408100654/src/install.c 2004-08-10 21:19:10 +0400 @@ -538,7 +538,7 @@ change_timestamps (const char *from, con if (stat (from, &stb)) { error (0, errno, _("cannot obtain time stamps for %s"), quote (from)); - return true; + return false; } timespec[0].tv_sec = stb.st_atime; @@ -548,9 +548,9 @@ change_timestamps (const char *from, con if (utimens (to, timespec)) { error (0, errno, _("cannot set time stamps for %s"), quote (to)); - return true; + return false; } - return false; + return true; } /* Strip the symbol table from the file PATH.
pgpp7iMOPVUtI.pgp
Description: PGP signature
_______________________________________________ Bug-coreutils mailing list [EMAIL PROTECTED] http://lists.gnu.org/mailman/listinfo/bug-coreutils