Index: src/bin/initdb/initdb.c =================================================================== RCS file: /projects/cvsroot/pgsql/src/bin/initdb/initdb.c,v retrieving revision 1.63 diff -c -r1.63 initdb.c *** src/bin/initdb/initdb.c 17 Oct 2004 21:04:41 -0000 1.63 --- src/bin/initdb/initdb.c 24 Oct 2004 14:45:40 -0000 *************** *** 422,429 **** --- 422,438 ---- } for (line = lines; *line != NULL; line++) { + #ifndef WIN32 if (fputs(*line, out_file) < 0) exit_nicely(); + #else + /* Make windows style linebreaks */ + (*line)[strlen(*line)-1] = 0; /* Cut away unix linebreak */ + if (fputs(*line, out_file) < 0) + exit_nicely(); + /* Now add a windows linebreak */ + fputs("\r\n", out_file); + #endif free(*line); } if (fclose(out_file))