home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1994 March / Source_Code_CD-ROM_Walnut_Creek_March_1994.iso / compsrcs / misc / volume29 / pdksh / patch05 < prev    next >
Encoding:
Text File  |  1992-05-12  |  19.2 KB  |  828 lines

  1. Newsgroups: comp.sources.misc
  2. From: sjg@zen.void.oz.au (Simon J. Gerraty)
  3. Subject:  v29i096:  pdksh - Public Domain Korn Shell, v4, Patch05
  4. Message-ID: <1992May13.145233.22940@sparky.imd.sterling.com>
  5. X-Md4-Signature: f3b0391fe6dd30da1f34dddff68ed064
  6. Date: Wed, 13 May 1992 14:52:33 GMT
  7. Approved: kent@sparky.imd.sterling.com
  8.  
  9. Submitted-by: sjg@zen.void.oz.au (Simon J. Gerraty)
  10. Posting-number: Volume 29, Issue 96
  11. Archive-name: pdksh/patch05
  12. Environment: UNIX
  13. Patch-To: pdksh: Volume 25, Issue 47-55
  14.  
  15. Ok, this should be it for a while.  I've built this version on a
  16. couple of System V machines and it seems ok.  I've fixed a
  17. couple of minor bugs, see ChangeLog files.
  18.  
  19. Apply this patch by changing directory to the root
  20. of the source tree and using the command:
  21.  
  22.     patch -p0 < this_file
  23.  
  24. The following is a complete list of patches to date.
  25.  
  26. # PD ksh Version 4
  27. Prereq: 09-Nov-91
  28. Prereq: 10-Nov-91
  29. Prereq: 25-Nov-91
  30. Prereq: 25-Apr-92
  31. Prereq: 26-Apr-92
  32. Prereq: 27-Apr-92
  33. *** PATCHDATES.old    Tue May 12 19:19:30 1992
  34. --- PATCHDATES    Tue May 12 19:30:05 1992
  35. ***************
  36. *** 5,7 ****
  37. --- 5,8 ----
  38.   25-Apr-92
  39.   26-Apr-92
  40.   27-Apr-92
  41. + 12-May-92
  42. *** ChangeLog.old    Sat Apr 25 10:57:37 1992
  43. --- ChangeLog    Sun May  3 18:25:42 1992
  44. ***************
  45. *** 1,3 ****
  46. --- 1,9 ----
  47. + Sun May  3 17:50:03 1992  Simon J. Gerraty  (sjg@zen)
  48. +     * Updated MACHINES.
  49. +     * Placed source under CVS.  This should help with processing fixes
  50. +     from the field.
  51.   Sat Apr 25 10:53:20 1992  Simon J. Gerraty  (sjg@zen)
  52.   
  53.       * Getting ready for 4.3 release.  
  54. *** MACHINES.old    Sat Apr 25 10:42:50 1992
  55. --- MACHINES    Sun May  3 18:25:48 1992
  56. ***************
  57. *** 1,4 ****
  58. ! This shell has been compiled on the following systems:
  59.   
  60.   Notes:
  61.   (1)    Built and tested by me (sjg), seems ok :-)
  62. --- 1,5 ----
  63. ! This file documents some the machines that pdksh has been build
  64. ! on and notes that apply.
  65.   
  66.   Notes:
  67.   (1)    Built and tested by me (sjg), seems ok :-)
  68. ***************
  69. *** 13,27 ****
  70.   
  71.   System, OS            Notes    Compiler/Flags
  72.   --------------------------    -----    --------------
  73. ! sun386, SunOS 4.0.2        1,4    gcc-2.1 -D_BSD
  74. ! sun386, SunOS 4.0.2        1,4    gcc-1.40 -D_BSD
  75. ! sun4c,    SunOS 4.1.1        1,4    gcc-2.1 -ansi -D_BSD -DHAVE_SYS_STDTYPES
  76. ! sun4c,    SunOS 4.1.1        1,4    cc -D_BSD -DHAVE_SYS_STDTYPES
  77. ! sun3,    SunOS 4.0.3        1,4    cc -D_BSD
  78. ! sun386, SunOS 4.0.2        1,5    cc -DNOSTDHDRS -D_BSD
  79. ! sun4c,    SunOS 4.1.1        1,5    cc -DNOSTDHDRS -D_BSD -DHAVE_SYS_STDTYPES
  80. ! sun3,    SunOS 4.0.3        1,5    cc -DNOSTDHDRS -D_BSD
  81. ! Bull DPX/2, B.O.S. 2.00.45    1,5    gcc-2.1 -ansi -D_POSIX_SOURCE
  82. ! Bull XPS-100            2,6
  83.   
  84.   
  85. --- 14,46 ----
  86.   
  87.   System, OS            Notes    Compiler/Flags
  88.   --------------------------    -----    --------------
  89. ! sun386, SunOS 4.0.2        1,4    {cc,gcc} -D_BSD
  90. ! sun4c,    SunOS 4.1.1        1,4    {cc,gcc-2.1} -ansi -D_BSD -DHAVE_SYS_STDTYPES
  91. ! sun3,    SunOS 4.0.3        1,4    {cc,gcc} -D_BSD
  92. ! sun3,    SunOS 4.1.1        1,4    {cc,gcc} -ansi -D_BSD -DHAVE_SYS_STDTYPES
  93. ! Bull DPX/2, B.O.S. 2.00.45    1,5    {cc,gcc-2.1} -ansi -D_POSIX_SOURCE
  94. ! Bull XPS-100            1,6    cc -D_SYSV -DUSE_SIGNAL
  95.   
  96. + NOTES:
  97. + The table above sumarizes the config used.  {cc,gcc} indicates
  98. + either compiler can be used.  If gcc-2.1 rather than gcc is
  99. + indicated then gcc < 2 may not work.  This is at least true of
  100. + sun4c (sparc) systems.
  101. + Bull DPX/2:
  102. + pdksh is not needed on this system.  It is simply used as a
  103. + System V / POSIX test bed.  Build without ./std tree.  I only
  104. + tried with gcc-2.1. -D_SYSV must be left out of CFLAGS for POSIX
  105. + functions such as sigaction() to be used.
  106. + Bull XPS-100:    
  107. + Be sure to rm std/h/dirent.h std/h/sys/types.h and undef JOBS as
  108. + the kernel does not support it.  This machine has a sigaction()
  109. + implementation that appears to be faulty.  A SIGINT terminates
  110. + the shell, when using the system's sigaction().  Undefining
  111. + USE_SIGACT does the trick.  sigact.c can now be forced to build
  112. + by defining USE_SIGNAL, but this is not tested on the XPS.
  113.   
  114. *** README.old    Sat Apr 25 17:59:10 1992
  115. --- README    Tue May 12 19:30:10 1992
  116. ***************
  117. *** 1,5 ****
  118.           Public Domain Korn Shell
  119. !               Version 4.3
  120.   
  121.   PD KSH:
  122.   
  123. --- 1,5 ----
  124.           Public Domain Korn Shell
  125. !               Version 4.5
  126.   
  127.   PD KSH:
  128.   
  129. *** bug-report.old    Tue May 12 19:19:30 1992
  130. --- bug-report    Tue May 12 19:30:14 1992
  131. ***************
  132. *** 2,8 ****
  133.   Subject: [area]: [synopsis]   [replace with actual area and short description]
  134.   
  135.   VERSION:
  136. !     PD KSH: 4.4 27-Apr-1992
  137.       [Official patches will edit this line to indicate the patch level]
  138.   
  139.   MACHINE and OPERATING SYSTEM:
  140. --- 2,8 ----
  141.   Subject: [area]: [synopsis]   [replace with actual area and short description]
  142.   
  143.   VERSION:
  144. !     PD KSH: 4.5 12-May-1992
  145.       [Official patches will edit this line to indicate the patch level]
  146.   
  147.   MACHINE and OPERATING SYSTEM:
  148. ***************
  149. *** 9,15 ****
  150.       [e.g. Sparc/SunOS 4.1.1, DECstation 3100/Ultrix 4.2, ...]
  151.   
  152.   COMPILER:
  153. !     [e.g. native cc, native ANSI cc, gcc 1.39, ...]
  154.   
  155.   AREA:
  156.       [Area of the source tree affected,
  157. --- 9,15 ----
  158.       [e.g. Sparc/SunOS 4.1.1, DECstation 3100/Ultrix 4.2, ...]
  159.   
  160.   COMPILER:
  161. !     [e.g. native cc, native ANSI cc, gcc 1.40, ...]
  162.   
  163.   AREA:
  164.       [Area of the source tree affected,
  165. ***************
  166. *** 24,30 ****
  167.        a fix]
  168.   
  169.   SAMPLE FIX:
  170. !     [Preferred, but not necessary.  Please send context diffs (diff -c)]
  171.   
  172.   [PLEASE make your Subject: line as descriptive as possible.
  173.    Subjects like "pdksh bug" or "bug report" are not helpful!]
  174. --- 24,31 ----
  175.        a fix]
  176.   
  177.   SAMPLE FIX:
  178. !     [Preferred, but not necessary.  Please send context diffs (diff -c)
  179. !      name old file first.  eg. diff -c file.c.old file.c]
  180.   
  181.   [PLEASE make your Subject: line as descriptive as possible.
  182.    Subjects like "pdksh bug" or "bug report" are not helpful!]
  183. *** etc/profile.old    Tue May 12 19:19:31 1992
  184. --- etc/profile    Sun May  3 18:28:27 1992
  185. ***************
  186. *** 12,18 ****
  187.   #    /etc/ksh.kshrc
  188.   #
  189.   # RCSid:
  190. ! #    $Id: profile,v 1.2 1992/04/27 07:09:54 sjg Exp $
  191.   #    @(#)Copyright (c) 1991 Simon J. Gerraty
  192.   #
  193.   #    This file is provided in the hope that it will
  194. --- 12,18 ----
  195.   #    /etc/ksh.kshrc
  196.   #
  197.   # RCSid:
  198. ! #    $Id: profile,v 1.3 1992/05/03 08:28:27 sjg Exp $
  199.   #    @(#)Copyright (c) 1991 Simon J. Gerraty
  200.   #
  201.   #    This file is provided in the hope that it will
  202. *** ksh.1.old    Sat Apr 25 18:15:59 1992
  203. --- ksh.1    Sat May  2 23:26:52 1992
  204. ***************
  205. *** 1,4 ****
  206. ! .\" $Id$
  207.   .nr OJ 1 \" Job Control
  208.   .nr OE 1 \" Command Editing
  209.   .nr OB 1 \" BSD enhanced ulimit options
  210. --- 1,4 ----
  211. ! .\" $Id: ksh.1,v 1.1 1992/05/02 13:26:52 sjg Exp $
  212.   .nr OJ 1 \" Job Control
  213.   .nr OE 1 \" Command Editing
  214.   .nr OB 1 \" BSD enhanced ulimit options
  215. *** sh/ChangeLog.old    Sat Apr 25 00:24:10 1992
  216. --- sh/ChangeLog    Tue May 12 19:30:27 1992
  217. ***************
  218. *** 1,3 ****
  219. --- 1,13 ----
  220. + Tue May 12 19:23:17 1992  Simon J. Gerraty  (sjg@zen)
  221. +     * Fix bug in init_editmode() if EMACS and VI are not both defined.
  222. + Sun May  3 17:47:54 1992  Simon J. Gerraty  (sjg@zen)
  223. +     * sigact.c:  allow force build if USE_* defined.
  224. +     * main.c: call init_editmode() _after_ processing /etc/profile.
  225. +     * jobs.c: ensure SA_RESTART is defined.
  226.   Sat Apr 25 00:20:51 1992  Simon J. Gerraty  (sjg@zen)
  227.   
  228.       * Implemented a simple history file.
  229. *** sh/config.h.old    Sat Apr 25 18:34:51 1992
  230. --- sh/config.h    Sun May  3 18:28:59 1992
  231. ***************
  232. *** 1,7 ****
  233.   /*
  234.    * Configuration file for the PD ksh
  235.    *
  236. !  * RCSid: $Id: config.h,v 1.2 1992/04/25 08:33:28 sjg Exp $
  237.    */
  238.   
  239.   #ifndef    _CONFIG_H
  240. --- 1,7 ----
  241.   /*
  242.    * Configuration file for the PD ksh
  243.    *
  244. !  * RCSid: $Id: config.h,v 1.3 1992/05/03 08:28:59 sjg Exp $
  245.    */
  246.   
  247.   #ifndef    _CONFIG_H
  248. ***************
  249. *** 24,33 ****
  250.    * if you don't have sigaction(2) and the
  251.    * implementation in sigact.c doesn't work for your system,
  252.    * fix it.
  253.    */
  254.   #define USE_SIGACT            /* POSIX signal handling */
  255.   
  256. ! #if defined(JOBS) && !defined(SIGCONT)
  257.   #undef JOBS
  258.   #endif
  259.   
  260. --- 24,46 ----
  261.    * if you don't have sigaction(2) and the
  262.    * implementation in sigact.c doesn't work for your system,
  263.    * fix it.
  264. +  * 
  265. +  * Of course if your system has a real sigaction() 
  266. +  * implementation that is faulty! undef JOBS and add USE_SIGNAL
  267. +  * or whatever does work.  You may find it necessary to undef
  268. +  * USE_SIGACT, if so please report it.
  269.    */
  270.   #define USE_SIGACT            /* POSIX signal handling */
  271. + /* 
  272. +  * These control how sigact.c implements sigaction()
  273. +  * If you don't define any of them it will try and work it out 
  274. +  * for itself.  The are listed in order of preference (usefulness).
  275. +  */
  276. + /* #define USE_SIGMASK            /* BSD4.2 ? signal handling */
  277. + /* #define USE_SIGSET            /* BSD4.1 ? signal handling */
  278. + /* #define USE_SIGNAL            /* plain old signal(2) */
  279.   
  280. ! #if defined(JOBS) && (!defined(SIGCONT) || (defined(_SYSV) && defined(USE_SIGNAL)))
  281.   #undef JOBS
  282.   #endif
  283.   
  284. *** sh/edit.c.old    Sat Apr 25 18:35:26 1992
  285. --- sh/edit.c    Tue May 12 19:30:31 1992
  286. ***************
  287. *** 7,13 ****
  288.   #if defined(EMACS) || defined(VI)
  289.   
  290.   #ifndef lint
  291. ! static char *RCSid = "$Id: edit.c,v 1.2 1992/04/25 08:33:28 sjg Exp $";
  292.   #endif
  293.   
  294.   #include "stdh.h"
  295. --- 7,13 ----
  296.   #if defined(EMACS) || defined(VI)
  297.   
  298.   #ifndef lint
  299. ! static char *RCSid = "$Id: edit.c,v 1.4 1992/05/12 09:30:31 sjg Exp $";
  300.   #endif
  301.   
  302.   #include "stdh.h"
  303. ***************
  304. *** 73,80 ****
  305.   #endif
  306.           i = -1;        /* internal error */
  307.       (void) x_mode(FALSE);
  308. !     /* XXX -- doesn't get them all */
  309. !     if (i > 4 && strncmp(buf, "stty", 4) == 0)
  310.           x_do_init = 1;
  311.       if (i < 0 && errno == EINTR)
  312.           trapsig(SIGINT);
  313. --- 73,79 ----
  314.   #endif
  315.           i = -1;        /* internal error */
  316.       (void) x_mode(FALSE);
  317. !     if (i > 4 && strstr(buf, "stty"))
  318.           x_do_init = 1;
  319.       if (i < 0 && errno == EINTR)
  320.           trapsig(SIGINT);
  321. ***************
  322. *** 454,459 ****
  323. --- 453,460 ----
  324.         flag[FVI] = 0;
  325.         flag[FEMACS] = 1;
  326.       }
  327. + #endif
  328. + #if defined(EMACS) && defined(VI)
  329.       else
  330.   #endif
  331.   #ifdef VI
  332. *** sh/main.c.old    Sat Apr 25 18:31:56 1992
  333. --- sh/main.c    Wed Apr 29 16:25:47 1992
  334. ***************
  335. *** 3,9 ****
  336.    */
  337.   
  338.   #ifndef lint
  339. ! static char *RCSid = "$Id: main.c,v 1.3 1992/04/25 08:29:52 sjg Exp $";
  340.   #endif
  341.   
  342.   #define    Extern                /* define Externs in sh.h */
  343. --- 3,9 ----
  344.    */
  345.   
  346.   #ifndef lint
  347. ! static char *RCSid = "$Id: main.c,v 1.4 1992/04/29 06:25:47 sjg Exp $";
  348.   #endif
  349.   
  350.   #define    Extern                /* define Externs in sh.h */
  351. ***************
  352. *** 235,243 ****
  353.   #else
  354.           (void) fd_clexec(ttyfd);
  355.   #endif
  356. - #if defined(EMACS) || defined(VI)
  357. -         init_editmode();
  358. - #endif
  359.   #ifdef EMACS
  360.           x_init_emacs();
  361.   #endif
  362. --- 235,240 ----
  363. ***************
  364. *** 273,278 ****
  365. --- 270,278 ----
  366.         signal(SIGTERM, trapsig);
  367.   #endif
  368.         ignoresig(SIGINT);
  369. + #if defined(EMACS) || defined(VI)
  370. +       init_editmode();
  371. + #endif
  372.       } else
  373.         flag[FHASHALL] = 1;
  374.   
  375. *** sh/patchlevel.h.old    Tue May 12 19:19:32 1992
  376. --- sh/patchlevel.h    Tue May 12 19:30:34 1992
  377. ***************
  378. *** 1,6 ****
  379.   /*
  380.    * PD KSH
  381. !  * $Id: patchlevel.h,v 4.4 1992/04/27 07:13:58 sjg Exp $
  382.    */
  383.   #define VERSION        4
  384. ! #define PATCHLEVEL    4
  385. --- 1,6 ----
  386.   /*
  387.    * PD KSH
  388. !  * $Id: patchlevel.h,v 4.5 1992/05/12 09:30:34 sjg Exp $
  389.    */
  390.   #define VERSION        4
  391. ! #define PATCHLEVEL    5
  392. *** sh/sigact.c.old    Tue May 12 19:19:32 1992
  393. --- sh/sigact.c    Sun May  3 18:29:10 1992
  394. ***************
  395. *** 60,69 ****
  396.    *
  397.    */
  398.   #ifndef lint
  399. ! static char  *RCSid = "$Id: sigact.c,v 1.3 1992/04/26 11:24:43 sjg Exp $";
  400.   #endif
  401.   /*
  402.    * $Log: sigact.c,v $
  403.    * Revision 1.3  1992/04/26  11:24:43  sjg
  404.    * USE_SIGSET corrected in sigsuspend().
  405.    *
  406. --- 60,75 ----
  407.    *
  408.    */
  409.   #ifndef lint
  410. ! static char  *RCSid = "$Id: sigact.c,v 1.5 1992/05/03 08:29:10 sjg Exp $";
  411.   #endif
  412.   /*
  413.    * $Log: sigact.c,v $
  414. +  * Revision 1.5  1992/05/03  08:29:10  sjg
  415. +  * Update for Patch05
  416. +  *
  417. +  * Revision 1.4  1992/04/29  06:29:13  sjg
  418. +  * avoid use of #pragma
  419. +  *
  420.    * Revision 1.3  1992/04/26  11:24:43  sjg
  421.    * USE_SIGSET corrected in sigsuspend().
  422.    *
  423. ***************
  424. *** 77,83 ****
  425.   
  426.   #include <signal.h>
  427.   
  428. ! #ifndef SA_NOCLDSTOP            /* no sigaction() */
  429.   
  430.   /*
  431.    * if we haven't been told,
  432. --- 83,93 ----
  433.   
  434.   #include <signal.h>
  435.   
  436. ! /*
  437. !  * some systems have a faulty sigaction() implementation!
  438. !  * Allow us to bypass it.
  439. !  */
  440. ! #if !defined(SA_NOCLDSTOP) || defined(USE_SIGNAL) || defined(USE_SIGSET) || defined(USE_SIGMASK)
  441.   
  442.   /*
  443.    * if we haven't been told,
  444. ***************
  445. *** 98,104 ****
  446.    * if we still don't know, we're in trouble
  447.    */
  448.   #if !defined(USE_SIGSET) && !defined(USE_SIGMASK) && !defined(USE_SIGNAL)
  449. ! #pragma error must know what to implement with
  450.   #endif
  451.   
  452.   #include "sigact.h"
  453. --- 108,114 ----
  454.    * if we still don't know, we're in trouble
  455.    */
  456.   #if !defined(USE_SIGSET) && !defined(USE_SIGMASK) && !defined(USE_SIGNAL)
  457. ! error must know what to implement with
  458.   #endif
  459.   
  460.   #include "sigact.h"
  461. ***************
  462. *** 179,188 ****
  463.   sigfillset(mask)
  464.     sigset_t *mask;
  465.   {
  466. !   register int i;
  467. !   
  468. !   for (i = 1; i < NSIG; i++)
  469. !     *mask |= sigmask(i);
  470.     return 0;
  471.   }
  472.   
  473. --- 189,195 ----
  474.   sigfillset(mask)
  475.     sigset_t *mask;
  476.   {
  477. !   *mask = ~0;
  478.     return 0;
  479.   }
  480.   
  481. *** sh/version.c.old    Sat Apr 25 18:38:04 1992
  482. --- sh/version.c    Tue May 12 19:30:37 1992
  483. ***************
  484. *** 3,9 ****
  485.    */
  486.   
  487.   #ifndef lint
  488. ! static char *RCSid = "$Id: version.c,v 1.2 1992/04/25 08:33:28 sjg Exp $";
  489.   #endif
  490.   
  491.   #include "stdh.h"
  492. --- 3,9 ----
  493.    */
  494.   
  495.   #ifndef lint
  496. ! static char *RCSid = "$Id: version.c,v 1.4 1992/05/12 09:30:37 sjg Exp $";
  497.   #endif
  498.   
  499.   #include "stdh.h"
  500. ***************
  501. *** 12,21 ****
  502.   #include "patchlevel.h"
  503.   
  504.   char ksh_version [] =
  505. !     "KSH_VERSION=@(#)PD KSH v4.3 92/04/25";
  506.   
  507.   /***
  508.   $Log: version.c,v $
  509.    * Revision 1.2  1992/04/25  08:33:28  sjg
  510.    * Added RCS key.
  511.    *
  512. --- 12,27 ----
  513.   #include "patchlevel.h"
  514.   
  515.   char ksh_version [] =
  516. !     "KSH_VERSION=@(#)PD KSH v4.5 92/05/12";
  517.   
  518.   /***
  519.   $Log: version.c,v $
  520. +  * Revision 1.4  1992/05/12  09:30:37  sjg
  521. +  * see ChangeLog
  522. +  *
  523. +  * Revision 1.3  1992/05/03  08:29:20  sjg
  524. +  * Update for Patch05
  525. +  *
  526.    * Revision 1.2  1992/04/25  08:33:28  sjg
  527.    * Added RCS key.
  528.    *
  529. *** std/stdc/ChangeLog.old    Sat Apr 25 14:52:16 1992
  530. --- std/stdc/ChangeLog    Tue May 12 19:30:54 1992
  531. ***************
  532. *** 1,3 ****
  533. --- 1,9 ----
  534. + Thu May  7 20:36:40 1992  Simon J. Gerraty  (sjg@zen)
  535. +     * fprintf.c: avoid use of #if __STDC__ some compilers don't handle it.
  536. +     * vprintf.c: avoid side effects from putc() macro!
  537.   Sat Apr 25 14:52:01 1992  Simon J. Gerraty  (sjg@zen)
  538.   
  539.       * Added RCS keys to sources.
  540. *** std/stdc/Makefile.old    Sat Apr 25 18:19:42 1992
  541. --- std/stdc/Makefile    Sun May  3 18:30:08 1992
  542. ***************
  543. *** 1,5 ****
  544.   # Standard C (ANSI) compatabilaty
  545. ! # $Id: Makefile,v 1.2 1992/04/25 08:19:26 sjg Exp $
  546.   
  547.   # edit this makefile such that only the functions that
  548.   # your systems doesn't have are provided.
  549. --- 1,5 ----
  550.   # Standard C (ANSI) compatabilaty
  551. ! # $Id: Makefile,v 1.3 1992/05/03 08:30:08 sjg Exp $
  552.   
  553.   # edit this makefile such that only the functions that
  554.   # your systems doesn't have are provided.
  555. ***************
  556. *** 56,63 ****
  557.   #    $(LIB)(strpbrk.o) \
  558.   #    $(LIB)(strrchr.o) \
  559.   #    $(LIB)(strspn.o) \
  560. ! #    $(LIB)(stdio.o) \
  561.   
  562.   
  563.   
  564. --- 56,63 ----
  565.   #    $(LIB)(strpbrk.o) \
  566.   #    $(LIB)(strrchr.o) \
  567.   #    $(LIB)(strspn.o) \
  568. ! #    $(LIB)(stdio.o) 
  569. ! #
  570.   
  571.   
  572.   
  573. *** std/stdc/fprintf.c.old    Sat Apr 25 18:19:51 1992
  574. --- std/stdc/fprintf.c    Tue May 12 19:30:58 1992
  575. ***************
  576. *** 2,10 ****
  577.    * printf and fprintf
  578.    */
  579.   
  580. ! /* $Id: fprintf.c,v 1.2 1992/04/25 08:19:26 sjg Exp $ */
  581.   
  582. ! #if __STDC__
  583.   #include <stdarg.h>
  584.   #else
  585.   #include <varargs.h>
  586. --- 2,10 ----
  587.    * printf and fprintf
  588.    */
  589.   
  590. ! /* $Id: fprintf.c,v 1.3 1992/05/12 09:30:58 sjg Exp $ */
  591.   
  592. ! #ifdef __STDC__
  593.   #include <stdarg.h>
  594.   #else
  595.   #include <varargs.h>
  596. ***************
  597. *** 15,21 ****
  598.   
  599.   /* printf to stdout */
  600.   int
  601. ! #if __STDC__
  602.   printf(const char *fmt, ...) {
  603.   #else
  604.   printf(va_alist) va_dcl
  605. --- 15,21 ----
  606.   
  607.   /* printf to stdout */
  608.   int
  609. ! #ifdef __STDC__
  610.   printf(const char *fmt, ...) {
  611.   #else
  612.   printf(va_alist) va_dcl
  613. ***************
  614. *** 24,30 ****
  615.   #endif
  616.       va_list va;
  617.   
  618. ! #if __STDC__
  619.       va_start(va, fmt);
  620.   #else
  621.       va_start(va);
  622. --- 24,30 ----
  623.   #endif
  624.       va_list va;
  625.   
  626. ! #ifdef __STDC__
  627.       va_start(va, fmt);
  628.   #else
  629.       va_start(va);
  630. ***************
  631. *** 36,42 ****
  632.   }
  633.   
  634.   int
  635. ! #if __STDC__
  636.   fprintf(FILE *f, const char *fmt, ...) {
  637.   #else
  638.   fprintf(va_alist) va_dcl
  639. --- 36,42 ----
  640.   }
  641.   
  642.   int
  643. ! #ifdef __STDC__
  644.   fprintf(FILE *f, const char *fmt, ...) {
  645.   #else
  646.   fprintf(va_alist) va_dcl
  647. ***************
  648. *** 46,52 ****
  649.   #endif
  650.       va_list va;
  651.   
  652. ! #if __STDC__
  653.       va_start(va, fmt);
  654.   #else
  655.       va_start(va);
  656. --- 46,52 ----
  657.   #endif
  658.       va_list va;
  659.   
  660. ! #ifdef __STDC__
  661.       va_start(va, fmt);
  662.   #else
  663.       va_start(va);
  664. *** std/stdc/sprintf.c.old    Sat Apr 25 18:20:23 1992
  665. --- std/stdc/sprintf.c    Tue May 12 19:31:01 1992
  666. ***************
  667. *** 2,10 ****
  668.    * sprintf and vsprintf
  669.    */
  670.   
  671. ! /* $Id: sprintf.c,v 1.2 1992/04/25 08:19:26 sjg Exp $ */
  672.   
  673. ! #if __STDC__
  674.   #include <stdarg.h>
  675.   #else
  676.   #include <varargs.h>
  677. --- 2,10 ----
  678.    * sprintf and vsprintf
  679.    */
  680.   
  681. ! /* $Id: sprintf.c,v 1.3 1992/05/12 09:31:01 sjg Exp $ */
  682.   
  683. ! #ifdef __STDC__
  684.   #include <stdarg.h>
  685.   #else
  686.   #include <varargs.h>
  687. ***************
  688. *** 14,20 ****
  689.   #if _V7 || _BSD
  690.   
  691.   int
  692. ! #if __STDC__
  693.   sprintf(char *s, const char *fmt, ...) {
  694.   #else
  695.   sprintf(va_alist) va_dcl
  696. --- 14,20 ----
  697.   #if _V7 || _BSD
  698.   
  699.   int
  700. ! #ifdef __STDC__
  701.   sprintf(char *s, const char *fmt, ...) {
  702.   #else
  703.   sprintf(va_alist) va_dcl
  704. ***************
  705. *** 25,31 ****
  706.       register va_list va;
  707.       int n;
  708.   
  709. ! #if __STDC__
  710.       va_start(va, fmt);
  711.   #else
  712.       va_start(va);
  713. --- 25,31 ----
  714.       register va_list va;
  715.       int n;
  716.   
  717. ! #ifdef __STDC__
  718.       va_start(va, fmt);
  719.   #else
  720.       va_start(va);
  721. ***************
  722. *** 38,44 ****
  723.   }
  724.   
  725.   int
  726. ! #if __STDC__
  727.   vsprintf(char *s, const char *fmt, va_list va) {
  728.   #else
  729.   vsprintf(s, fmt, va)
  730. --- 38,44 ----
  731.   }
  732.   
  733.   int
  734. ! #ifdef __STDC__
  735.   vsprintf(char *s, const char *fmt, va_list va) {
  736.   #else
  737.   vsprintf(s, fmt, va)
  738. *** std/stdc/stdio.h_std.old    Sat Apr 25 14:42:26 1992
  739. --- std/stdc/stdio.h_std    Sat May  2 23:29:18 1992
  740. ***************
  741. *** 5,11 ****
  742.    * todo: needs L_* constants.
  743.    */
  744.   
  745. ! /* $Id$ */
  746.   
  747.   #if ! _STDIO_H
  748.   #define    _STDIO_H 1
  749. --- 5,11 ----
  750.    * todo: needs L_* constants.
  751.    */
  752.   
  753. ! /* $Id: stdio.h_std,v 1.1 1992/05/02 13:29:18 sjg Exp $ */
  754.   
  755.   #if ! _STDIO_H
  756.   #define    _STDIO_H 1
  757. *** std/stdc/vprintf.c.old    Sat Apr 25 18:21:26 1992
  758. --- std/stdc/vprintf.c    Tue May 12 19:31:03 1992
  759. ***************
  760. *** 1,5 ****
  761.   #ifndef lint
  762. ! static char *RCSid = "$Id: vprintf.c,v 1.2 1992/04/25 08:19:26 sjg Exp $";
  763.   #endif
  764.   #ifdef __STDC__
  765.   #include <stdarg.h>
  766. --- 1,5 ----
  767.   #ifndef lint
  768. ! static char *RCSid = "$Id: vprintf.c,v 1.3 1992/05/12 09:31:03 sjg Exp $";
  769.   #endif
  770.   #ifdef __STDC__
  771.   #include <stdarg.h>
  772. ***************
  773. *** 144,150 ****
  774.               if ((flags&FF_PREC) && strlen(p) > prec) {
  775.                   pos += prec;
  776.                   while (--prec >= 0)
  777. !                     putc(*p++, f);
  778.                   break;
  779.               }
  780.               flags |= FF_PUTS;
  781. --- 144,153 ----
  782.               if ((flags&FF_PREC) && strlen(p) > prec) {
  783.                   pos += prec;
  784.                   while (--prec >= 0)
  785. !                 {
  786. !                   c = *p++;
  787. !                   putc(c, f);
  788. !                 }
  789.                   break;
  790.               }
  791.               flags |= FF_PUTS;
  792. ***************
  793. *** 223,230 ****
  794.               if (!(flags&FF_LEFT))
  795.                   while (--pad >= 0)
  796.                       putc((flags&FF_ZERO) ? '0' : ' ', f);
  797. !             while (*p)
  798. !                 putc(*p++, f);
  799.               if ((flags&FF_LEFT))
  800.                   while (--pad >= 0)
  801.                       putc(' ', f);
  802. --- 226,233 ----
  803.               if (!(flags&FF_LEFT))
  804.                   while (--pad >= 0)
  805.                       putc((flags&FF_ZERO) ? '0' : ' ', f);
  806. !             while (c = *p++)
  807. !                 putc(c, f);
  808.               if ((flags&FF_LEFT))
  809.                   while (--pad >= 0)
  810.                       putc(' ', f);
  811.  
  812. exit 0 # Just in case...
  813.