home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / listings / v_08_01 / 8n01030a < prev    next >
Text File  |  1990-02-19  |  479b  |  24 lines

  1.  
  2.  
  3. Listing 3
  4.  
  5.  
  6. #define MAXDATEPRINTS 2   /* at least 2, maybe more */
  7. 
  8.  
  9. date_print(i)
  10. date i; /* internal date form */
  11. {
  12.         static printable_date date[MAXDATEPRINTS];
  13.         static inuse = 0;
  14.  
  15.         inuse = (inuse+1)%MAXDATEPRINTS;        /* use next buffer */
  16.         
  17.         /* actually do the work and convert date */
  18.         /* into a printable representation */
  19.         .....
  20.         memcpy(date[inuse],....);
  21.         return(date[inuse]);
  22. }
  23.  
  24.