| index bae1882..bc1ecf1 100644 | | index bae1882..bc1ecf1 100644 |
| --- a/src/plugin_sqlite.c | | --- a/src/plugin_sqlite.c |
| +++ b/src/plugin_sqlite.c | | +++ b/src/plugin_sqlite.c |
| @@ -61,18 +61,6 @@ static void sx_plugin_binary_stdio(void) { | | @@ -61,18 +61,6 @@ static void sx_plugin_binary_stdio(void) { |
| 61 | _setmode(_fileno(stdout), _O_BINARY); | 61 | _setmode(_fileno(stdout), _O_BINARY); |
| 62 | _setmode(_fileno(stdin), _O_BINARY); | 62 | _setmode(_fileno(stdin), _O_BINARY); |
| 63 | } | 63 | } |
| 64 | -# include <fcntl.h> | | |
| 65 | -/* MinGW/MSVC CRT starts stdout in TEXT mode, which rewrites every \n we emit | | |
| 66 | - * into \r\n. A CGI header block must end with exactly CRLF CRLF; text mode | | |
| 67 | - * turns "\r\n\r\n" into "\r\r\n\r\r\n", scorpiox-server cannot find the | | |
| 68 | - * header/body separator, and the whole reply (headers included) is served as a | | |
| 69 | - * body with Content-Type: text/html. Force binary stdio before main() runs — | | |
| 70 | - * the same constructor scorpiox-bot-api handlers use (sx_shell.h). */ | | |
| 71 | -__attribute__((constructor)) | | |
| 72 | -static void sx_plugin_binary_stdio(void) { | | |
| 73 | - _setmode(_fileno(stdout), _O_BINARY); | | |
| 74 | - _setmode(_fileno(stdin), _O_BINARY); | | |
| 75 | -} | | |
| 76 | # include <sys/stat.h> | 64 | # include <sys/stat.h> |
| 77 | # define SX_STAT struct _stat64 | 65 | # define SX_STAT struct _stat64 |
| 78 | # define sx_stat(p,s) _stat64((p),(s)) | 66 | # define sx_stat(p,s) _stat64((p),(s)) |
| 79 | | 67 | |