typedef signed long int32;
#else
#if SILC_SIZEOF_LONG_LONG >= 4
+#ifndef WIN32
typedef unsigned long long uint32;
typedef signed long long int32;
#endif
#endif
#endif
+#endif
#if SILC_SIZEOF_LONG >= 8
typedef unsigned long uint64;
typedef signed long int64;
#else
#if SILC_SIZEOF_LONG_LONG >= 8
+#ifndef WIN32
typedef unsigned long long uint64;
typedef signed long long int64;
+#endif
#else
typedef uint32 uint64;
typedef int32 int64;
void silc_client_replace_from_channels(SilcClient client,
SilcClientConnection conn,
SilcClientEntry old,
- SilcClientEntry new);
+ SilcClientEntry newclient);
void silc_client_process_failure(SilcClient client,
SilcSocketConnection sock,
SilcPacketContext *packet);
break;
}
+ if (!filename)
+ filename = " ";
+
/* Purge the log file if the max size is defined. */
if (maxsize) {
fp = fopen(filename, "r");
/* $Id$ */
#include "silcincludes.h"
-#includd "silcschedule_i.h"
+#include "silcschedule_i.h"
/* Our "select()" for WIN32. This mimics the behaviour of select() system
call. It does not call the Winsock's select() though. Its functions
continue;
if (fds[i].events & SILC_TASK_READ)
- handles[nhandles++] = (HANDLE)i;
+ handles[nhandles++] = (HANDLE)fds[i].fd;
- if (fds[i].events & SILC_TASK_WRITE)
+ /* If writing then just set the bit and return */
+ if (fds[i].events & SILC_TASK_WRITE) {
+ fds[i].revents = SILC_TASK_WRITE;
return 1;
+ }
fds[i].revents = 0;
}
/* Give the wait another try */
goto retry;
- } else if (ready >= WAIT_OBJECT_0 && ready < WAIT_OBJECT_0 + nhandles &&
- readfds) {
+ } else if (ready >= WAIT_OBJECT_0 && ready < WAIT_OBJECT_0 + nhandles) {
/* Some other event, like SOCKET or something. */
/* Go through all fds even though only one was set. This is to avoid