home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1995 April / Internet Tools.iso / mail / listserv / NeXT / 2.1.diffs.Z / 2.1.diffs
Encoding:
Internet Message Format  |  1993-10-31  |  2.0 KB

  1. From jladwig@soils.umn.edu Thu Sep  9 09:55:36 1993
  2. Return-Path: <jladwig@soils.umn.edu>
  3. Received: from saturn.soils.umn.edu by cs-mail.bu.edu (5.61+++/Spike-2.1)
  4.     id AA20847; Thu, 9 Sep 93 09:55:34 -0400
  5. Received: by saturn.soils.umn.edu (4.1)
  6.     id AA18878; Thu, 9 Sep 93 08:54:00 CDT
  7. Date: Thu, 9 Sep 93 08:54:00 CDT
  8. From: "John Ladwig" <jladwig@soils.umn.edu>
  9. Message-Id: <9309091354.AA18878@saturn.soils.umn.edu>
  10. To: tasos@cs.bu.edu (Anastasios Kotsikonas)
  11. Subject: Re: Listproc-6.0a to NeXTSTEP 2.1
  12. In-Reply-To: Anastasios Kotsikonas's message <9309091345.AA18778@cs.bu.edu> of 9 September 1993
  13. References: <199309081909.AA20564@nx1.soils.umn.edu>
  14.     <9309091345.AA18778@cs.bu.edu>
  15. Status: RO
  16.  
  17. Anastasios Kotsikonas <tasos@cs.bu.edu > writes on 9 September 1993 at 09:45:17 -0400
  18.  > > How come we seem to have SysV flavor?
  19.  > 
  20.  > It recognizes sigblock() and sirelse(), which are pure SYSV calls. Notice
  21.  > it says it's got SYSV "flavor".
  22.  
  23. OK, that makes sense.
  24.  
  25. Compilation went just swell, however, it appears that there is a
  26. serious bug in the NS2.1 tmpnam function, which doesn't generate
  27. unique names after multiple calls with a NULL argument.  This bug in
  28. the library *may* have been what caused me to lose *both* the
  29. .subscribers and .aliases file on my list recently.  That was one of
  30. the things that got me looking seriously at 6.0a
  31.  
  32. start was dying on the first go-round because the tmpps and tmpfound
  33. files were turning out to have the same name, which zero'd out the
  34. tmpfound file.  Bad.
  35.  
  36. Here's the replacement tmpnam I cobbled together, sorta based on the
  37. BSD NET2 version, although by no means as robust, it seems to do the
  38. right thing.
  39.  
  40. I added a -DBROKEN_TMPNAM to the flags in Makefile and all *seems*
  41. well during initial testing.
  42.  
  43.  
  44. /* General compatibility routines */
  45.  
  46. #include <stdio.h>
  47.  
  48.  
  49. #ifdef BROKEN_TMPNAM
  50.  
  51. /* For those who have a broken tmpnam (like NeXTSTEP 2.1) */
  52.  
  53. char *tmpnam(char *name)
  54. {
  55.   static char space[L_tmpnam+1];
  56.   
  57.   if (name == NULL) 
  58.     name = space;
  59.   
  60.   sprintf(name, "/tmp/tmp.XXXXXX");
  61.   
  62.   return ((char *)mktemp(name));
  63. }
  64.  
  65. #endif
  66.  
  67.