Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/po/sjiscorr.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@ main(int argc, char **argv)
char buffer[BUFSIZ];
char *p;

// Windows only: switch standard output to binary mode, which ensures that
// the line endings in ja.sjis.po are LF.
// Windows only: put standard input and output into binary mode so that the
// line endings in the output match those in the input.
#ifdef _WIN32
_setmode(_fileno(stdin), _O_BINARY);
_setmode(_fileno(stdout), _O_BINARY);
#endif

Expand All @@ -32,11 +33,10 @@ main(int argc, char **argv)
fputs("charset=CP932", stdout);
p += 12;
}
else if (strncmp(p, "# Original translations", 23) == 0)
else if (strncmp(p, "# Original translations.", 24) == 0)
{
p += 24 - 1; // subtracting 1 by considering "p++" in the loop.
fputs("# Generated from ja.po, DO NOT EDIT.", stdout);
while (p[1] != '\n')
++p;
}
else if (*(unsigned char *)p == 0x81 && p[1] == '_')
{
Expand Down