home *** CD-ROM | disk | FTP | other *** search
/ Mega Top 1 / os2_top1.zip / os2_top1 / APPS / TEKST / DVIDVI / PATCHES.OS2 < prev    next >
Text File  |  1992-08-29  |  1KB  |  51 lines

  1. *** dvidvi.c    Wed Apr 29 03:29:22 1992
  2. --- ../dvidvi.c    Sat Aug 29 14:10:02 1992
  3. ***************
  4. *** 34,39 ****
  5. --- 34,45 ----
  6.   #ifndef VMS
  7.   #include <stdio.h>
  8.   #include <string.h>
  9. + #ifdef MSDOS
  10. + #include <stdlib.h>
  11. + #include <fcntl.h>             /* for setmode() */
  12. + #include <io.h>
  13. + #include "prototyp.h"
  14. + #endif
  15.   #else /* VMS */
  16.   #include "sys$library:stdio.h"       /* AKT: added sys$library: */
  17.   #include <alloc.h>
  18. ***************
  19. *** 572,580 ****
  20.              p++; firsttransf = 1 ;
  21.              }
  22.   #ifdef SHORTINT
  23. -             if(sscanf(p, "%d", &firstpage)==0)
  24. - #else   /* ~SHORTINT */
  25.               if(sscanf(p, "%ld", &firstpage)==0)
  26.   #endif  /* ~SHORTINT */
  27.              error("! Bad first page option (-f).") ;
  28.               break ;
  29. --- 578,586 ----
  30.              p++; firsttransf = 1 ;
  31.              }
  32.   #ifdef SHORTINT
  33.               if(sscanf(p, "%ld", &firstpage)==0)
  34. + #else   /* ~SHORTINT */
  35. +             if(sscanf(p, "%d", &firstpage)==0)
  36.   #endif  /* ~SHORTINT */
  37.              error("! Bad first page option (-f).") ;
  38.               break ;
  39. ***************
  40. *** 796,801 ****
  41. --- 802,810 ----
  42.          (void)fprintf(stderr, "%s -> %s\n",iname,oname);
  43.          temp = nextstring ;
  44.      }
  45. + #ifdef MSDOS
  46. +     setmode(fileno(stdout), O_BINARY);
  47. + #endif
  48.   }
  49.   /*
  50.    *   Grabs a pointer, and checks it for validity.
  51.