Fossil SCM

Patches to get Fossil working on OS/2. Ticket [89bec0d9aa9f30]

drh 2009-08-29 17:01 trunk
Commit df97fae2bd9f248be088a57f67fd6c46c635c357
2 files changed +3 +5
+3
--- src/cgi.c
+++ src/cgi.c
@@ -40,10 +40,13 @@
4040
# include <sys/times.h>
4141
# include <sys/time.h>
4242
# include <sys/wait.h>
4343
# include <sys/select.h>
4444
#endif
45
+#ifdef __EMX__
46
+ typedef int socklen_t;
47
+#endif
4548
#include <time.h>
4649
#include <stdio.h>
4750
#include <stdlib.h>
4851
#include <unistd.h>
4952
#include "cgi.h"
5053
--- src/cgi.c
+++ src/cgi.c
@@ -40,10 +40,13 @@
40 # include <sys/times.h>
41 # include <sys/time.h>
42 # include <sys/wait.h>
43 # include <sys/select.h>
44 #endif
 
 
 
45 #include <time.h>
46 #include <stdio.h>
47 #include <stdlib.h>
48 #include <unistd.h>
49 #include "cgi.h"
50
--- src/cgi.c
+++ src/cgi.c
@@ -40,10 +40,13 @@
40 # include <sys/times.h>
41 # include <sys/time.h>
42 # include <sys/wait.h>
43 # include <sys/select.h>
44 #endif
45 #ifdef __EMX__
46 typedef int socklen_t;
47 #endif
48 #include <time.h>
49 #include <stdio.h>
50 #include <stdlib.h>
51 #include <unistd.h>
52 #include "cgi.h"
53
+5
--- src/main.c
+++ src/main.c
@@ -625,10 +625,15 @@
625625
/* Set binary mode on windows to avoid undesired translations
626626
** between \n and \r\n. */
627627
setmode(_fileno(g.httpOut), _O_BINARY);
628628
setmode(_fileno(g.httpIn), _O_BINARY);
629629
#endif
630
+#ifdef __EMX__
631
+ /* Similar hack for OS/2 */
632
+ setmode(fileno(g.httpOut), O_BINARY);
633
+ setmode(fileno(g.httpIn), O_BINARY);
634
+#endif
630635
g.cgiPanic = 1;
631636
blob_read_from_file(&config, zFile);
632637
while( blob_line(&config, &line) ){
633638
if( !blob_token(&line, &key) ) continue;
634639
if( blob_buffer(&key)[0]=='#' ) continue;
635640
--- src/main.c
+++ src/main.c
@@ -625,10 +625,15 @@
625 /* Set binary mode on windows to avoid undesired translations
626 ** between \n and \r\n. */
627 setmode(_fileno(g.httpOut), _O_BINARY);
628 setmode(_fileno(g.httpIn), _O_BINARY);
629 #endif
 
 
 
 
 
630 g.cgiPanic = 1;
631 blob_read_from_file(&config, zFile);
632 while( blob_line(&config, &line) ){
633 if( !blob_token(&line, &key) ) continue;
634 if( blob_buffer(&key)[0]=='#' ) continue;
635
--- src/main.c
+++ src/main.c
@@ -625,10 +625,15 @@
625 /* Set binary mode on windows to avoid undesired translations
626 ** between \n and \r\n. */
627 setmode(_fileno(g.httpOut), _O_BINARY);
628 setmode(_fileno(g.httpIn), _O_BINARY);
629 #endif
630 #ifdef __EMX__
631 /* Similar hack for OS/2 */
632 setmode(fileno(g.httpOut), O_BINARY);
633 setmode(fileno(g.httpIn), O_BINARY);
634 #endif
635 g.cgiPanic = 1;
636 blob_read_from_file(&config, zFile);
637 while( blob_line(&config, &line) ){
638 if( !blob_token(&line, &key) ) continue;
639 if( blob_buffer(&key)[0]=='#' ) continue;
640

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button