home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD2.mdf / gnu / djgpp / diffs / libgplus.5 / libio / filebuf.cc < prev    next >
Encoding:
Text File  |  1993-12-14  |  814 b   |  34 lines

  1. *** orig/libgplus.5/libio/filebuf.cc    Sat Nov 13 18:08:46 1993
  2. --- src/libgplus.5/libio/filebuf.cc    Sat Nov 13 19:07:48 1993
  3. ***************
  4. *** 24,30 ****
  5. --- 24,34 ----
  6.   
  7.   Written by Per Bothner (bothner@cygnus.com). */
  8.   
  9. + #ifdef __MSDOS__
  10. + #include "iostreaP.h"
  11. + #else
  12.   #include "iostreamP.h"
  13. + #endif
  14.   #include <sys/types.h>
  15.   #include <sys/stat.h>
  16.   #include <fcntl.h>
  17. ***************
  18. *** 102,107 ****
  19. --- 106,119 ----
  20.       posix_mode |= O_CREAT;
  21.     if (mode & (int)ios::noreplace)
  22.       posix_mode |= O_EXCL;
  23. + #ifdef O_BINARY
  24. +   if (mode & (int)ios::binary)
  25. +     posix_mode |= O_BINARY;
  26. + #endif
  27. + #ifdef O_TEXT
  28. +   if (mode & (int)ios::text)
  29. +     posix_mode |= O_TEXT;
  30. + #endif
  31.     int fd = ::open(filename, posix_mode, prot);
  32.     if (fd < 0)
  33.       return NULL;
  34.