]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
- Fixes for 64bit windows compile.
authorWouter Wijngaards <wouter@nlnetlabs.nl>
Tue, 5 Jul 2016 07:40:13 +0000 (07:40 +0000)
committerWouter Wijngaards <wouter@nlnetlabs.nl>
Tue, 5 Jul 2016 07:40:13 +0000 (07:40 +0000)
git-svn-id: file:///svn/unbound/trunk@3808 be551aaa-1e26-0410-a405-d3ace91eadb9

doc/Changelog
smallapp/unbound-anchor.c
util/winsock_event.c
validator/autotrust.c

index 3edb17d1d47680e84b36e5af68e8a2888d1c9ec6..1b83c708a544a35784bc611e42fd72ebab7599ac 100644 (file)
@@ -1,6 +1,7 @@
 5 July 2016: Wouter
        - Fix dynamic link of anchor-update.exe on windows.
        - Fix detect of mingw for MXE package build.
+       - Fixes for 64bit windows compile.
 
 4 July 2016: Wouter
        - For #787: prefer-ip6 option for unbound.conf prefers to send
index 81bb896f7170d0ceffecd6147aa02210a59f6a11..16009d845cd7b1f1f4bd8a5fab8ce1af7066958c 100644 (file)
@@ -1836,7 +1836,7 @@ write_unsigned_root(const char* root_anchor_file)
 #ifdef HAVE_FSYNC
        fsync(fileno(out));
 #else
-       FlushFileBuffers((HANDLE)_fileno(out));
+       FlushFileBuffers((HANDLE)get_osfhandle(_fileno(out)));
 #endif
        fclose(out);
 }
@@ -1868,7 +1868,7 @@ write_root_anchor(const char* root_anchor_file, BIO* ds)
 #ifdef HAVE_FSYNC
        fsync(fileno(out));
 #else
-       FlushFileBuffers((HANDLE)_fileno(out));
+       FlushFileBuffers((HANDLE)get_osfhandle(_fileno(out)));
 #endif
        fclose(out);
 }
index 40b79821a478aefb03097c7207a9bb818286d205..9aad27edc0bc80214cf49d0e1f2017cfd877241d 100644 (file)
@@ -262,8 +262,9 @@ static int handle_select(struct event_base* base, struct timeval* wait)
                        break; /* sanity check */
        }
        log_assert(numwait <= WSA_MAXIMUM_WAIT_EVENTS);
-       verbose(VERB_CLIENT, "winsock_event bmax=%d numwait=%d wait=%x "
-               "timeout=%d", base->max, numwait, (int)wait, (int)timeout);
+       verbose(VERB_CLIENT, "winsock_event bmax=%d numwait=%d wait=%s "
+               "timeout=%d", base->max, numwait, (wait?"<wait>":"<null>"),
+               (int)timeout);
 
        /* do the wait */
        if(numwait == 0) {
index 232397c31069f821f4158af98aa1249a653e4b38..a5924f0ed374b6be063941702cf61fe02722d6a6 100644 (file)
@@ -1201,7 +1201,7 @@ void autr_write_file(struct module_env* env, struct trust_anchor* tp)
        if(fsync(fileno(out)) != 0)
                log_err("could not fsync(%s): %s", fname, strerror(errno));
 #else
-       FlushFileBuffers((HANDLE)_fileno(out));
+       FlushFileBuffers((HANDLE)get_osfhandle(_fileno(out)));
 #endif
        if(fclose(out) != 0) {
                fatal_exit("could not complete write: %s: %s",