WinCE patches
[openssl.git] / apps / s_server.c
index e39a8f7f1a65c25731b0bfcced3eb17c89ba6771..4d87567a62cc91c2572c4a4f4e22bc67ffb97c7d 100644 (file)
@@ -149,6 +149,14 @@ typedef unsigned int u_int;
 #include <conio.h>
 #endif
 
+#ifdef OPENSSL_SYS_WINCE
+/* Windows CE incorrectly defines fileno as returning void*, so to avoid problems below... */
+#ifdef fileno
+#undef fileno
+#endif
+#define fileno(a) (int)_fileno(a)
+#endif
+
 #if (defined(OPENSSL_SYS_VMS) && __VMS_VER < 70000000)
 /* FIONBIO used as a switch to enable ioctl, and that isn't in VMS < 7.0 */
 #undef FIONBIO
@@ -1473,7 +1481,7 @@ static int www_body(char *hostname, int s, unsigned char *context)
                        else
                                {
                                BIO_printf(bio_s_out,"read R BLOCK\n");
-#ifndef OPENSSL_SYS_MSDOS
+#if !defined(OPENSSL_SYS_MSDOS) && !defined(__DJGPP__)
                                sleep(1);
 #endif
                                continue;