win32 more build fixes
[platform/upstream/libwebsockets.git] / lib / lws-plat-win.c
index 67c3c12..842423b 100644 (file)
@@ -31,7 +31,10 @@ time_in_microseconds()
 time_t time(time_t *t)
 {
        time_t ret = time_in_microseconds() / 1000000;
-       *t = ret;
+
+       if(t != NULL)
+               *t = ret;
+
        return ret;
 }
 #endif
@@ -541,7 +544,6 @@ _lws_plat_file_read(struct lws *wsi, lws_filefd_type fd, unsigned long *amount,
 {
        DWORD _amount;
 
-       (void *)wsi;
        if (!ReadFile((HANDLE)fd, buf, (DWORD)len, &_amount, NULL)) {
                *amount = 0;