home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume22 / cvs-berliner / patch01 < prev    next >
Encoding:
Internet Message Format  |  1990-06-07  |  2.5 KB

  1. Subject:  v22i033:  Patch to Brian Berliner's CVS system, Patch1
  2. Newsgroups: comp.sources.unix
  3. Approved: rsalz@uunet.UU.NET
  4. X-Checksum-Snefru: fbd558cb 89d41894 54bfd8cf 7782ddba
  5.  
  6. Submitted-by: Brian Berliner <berliner@sun.com>
  7. Posting-number: Volume 22, Issue 33
  8. Archive-name: cvs-berliner/patch1
  9. Patch-To: volume22/cvs-berliner
  10.  
  11. This patch addresses a major portability bug and is very small.  It will
  12. probably be the only patch I send out for this version of CVS.  The 2.0
  13. release of CVS is almost complete, and I'll likely be sending that one to
  14. you in a couple of months.
  15.  
  16.     -Brian
  17.     berliner@sun.com
  18.  
  19. ---------CUT-FOR-PATCH---------CUT-FOR-PATCH---------CUT-FOR-PATCH----------
  20. This patch fixes a major portability bug in the 1.0 release of CVS.  Apply
  21. the following patch with the "patch" command or by hand.  Also, my new email
  22. address is:
  23.  
  24.     berliner@sun.com
  25.  
  26. Please direct all future inquiries about CVS to this address.
  27.  
  28.     -Brian
  29.  
  30. diff -c cvs/src/patch.c:1.5 cvs/src/patch.c:1.6
  31. *** cvs/src/patch.c:1.5    Wed Feb 14 10:02:10 1990
  32. --- cvs/src/patch.c    Wed Feb 14 10:02:10 1990
  33. ***************
  34. *** 1,5 ****
  35.   #ifndef lint
  36. ! static char rcsid[] = "$Id: patch.c,v 1.5 89/11/19 23:40:41 berliner Exp $";
  37.   #endif !lint
  38.   
  39.   /*
  40. --- 1,5 ----
  41.   #ifndef lint
  42. ! static char rcsid[] = "$Id: patch.c,v 1.6 90/02/14 10:01:33 berliner Exp $";
  43.   #endif !lint
  44.   
  45.   /*
  46. ***************
  47. *** 22,28 ****
  48.   #include <ctype.h>
  49.   #include "cvs.h"
  50.   
  51. ! extern time_t timelocal();
  52.   
  53.   extern char update_dir[];
  54.   extern DBM *open_module();
  55. --- 22,28 ----
  56.   #include <ctype.h>
  57.   #include "cvs.h"
  58.   
  59. ! extern long maketime();
  60.   
  61.   extern char update_dir[];
  62.   extern DBM *open_module();
  63. ***************
  64. *** 380,391 ****
  65.           ret = 0;
  66.           *semi = '\0';
  67.           ftm = &tm;
  68. !         bzero((char *)ftm, sizeof(*ftm));
  69.           (void) sscanf(cp, DATEFORM, &ftm->tm_year, &ftm->tm_mon,
  70.                     &ftm->tm_mday, &ftm->tm_hour, &ftm->tm_min,
  71.                     &ftm->tm_sec);
  72.           ftm->tm_mon--;
  73. !         revdate = timelocal(ftm) - 1;
  74.           ftm = localtime(&revdate);
  75.           (void) sprintf(date, DATEFORM, ftm->tm_year, ftm->tm_mon+1,
  76.                      ftm->tm_mday, ftm->tm_hour, ftm->tm_min,
  77. --- 380,391 ----
  78.           ret = 0;
  79.           *semi = '\0';
  80.           ftm = &tm;
  81. !         zaptime((int *)ftm);
  82.           (void) sscanf(cp, DATEFORM, &ftm->tm_year, &ftm->tm_mon,
  83.                     &ftm->tm_mday, &ftm->tm_hour, &ftm->tm_min,
  84.                     &ftm->tm_sec);
  85.           ftm->tm_mon--;
  86. !         revdate = (time_t)maketime(ftm) - 1;
  87.           ftm = localtime(&revdate);
  88.           (void) sprintf(date, DATEFORM, ftm->tm_year, ftm->tm_mon+1,
  89.                      ftm->tm_mday, ftm->tm_hour, ftm->tm_min,
  90.  
  91. exit 0 # Just in case...
  92.