Remove special handling for open() in initdb for Windows

40cfe86 enforces the translation mode to text for all frontends, so this
special handling in initdb is not needed anymore.
pull/34/head
Michael Paquier 7 years ago
parent c9a8a401f1
commit 925673f27b
  1. 8
      src/bin/initdb/initdb.c

@ -491,15 +491,7 @@ readfile(const char *path)
char *buffer; char *buffer;
int c; int c;
#ifdef WIN32
/*
* On Windows, we have to open the file in text mode so that carriage
* returns are stripped.
*/
if ((infile = fopen(path, "rt")) == NULL)
#else
if ((infile = fopen(path, "r")) == NULL) if ((infile = fopen(path, "r")) == NULL)
#endif
{ {
fprintf(stderr, _("%s: could not open file \"%s\" for reading: %s\n"), fprintf(stderr, _("%s: could not open file \"%s\" for reading: %s\n"),
progname, path, strerror(errno)); progname, path, strerror(errno));

Loading…
Cancel
Save