Ticket Change Details
Not logged in

Changes to ticket c62fac40af

By anonymous on 2008-11-19 23:52:05. See also: artifact content, and ticket history

    1. Appended to comment:

      anonymous added on 2008-11-19 23:52:05:
      Thanks for the fix, drh.

      • Bad news: I'm afraid it didn't really fix it. The contents of the EditCSS textbox still have extra \r , so line spacing increases by one after every edit.
      • Good news: stdout can be made binary with setmode(), which prevents the \n to \r\n translation.
      Patches for main.c:
      
      {line 30, in header includes}
      = #include <time.h>
      + #ifdef __MINGW32__
      + /* Define file mode constants */
      + #include <fcntl.h>
      + #endif
      
      {line 615, in cmd_cgi() }
      =  g.httpOut = stdout;
      + #ifdef __MINGW32__
      +   /* prevent \n to \r \n translation on Windows */
      +   setmode( _fileno(g.httpOut), _O_BINARY );
      + #endif
      
      The workaround in cgi.c, function cgi_reply() , is no longer necessary; the content-length header is valid.
      

      Full diffs will be posted on the fossil-users mailing list.

      Environment: Windows Vista, Apache httpd 2.2.9, mod_cgi, fossil 63886daad8 2008-11-18 15:33:25 UTC

    2. Change status to "Open"