X-Git-Url: https://tinc-vpn.org/git/browse?a=blobdiff_plain;ds=sidebyside;f=src%2Fmingw%2Fdevice.c;h=03a1d48c1f39a261f01b4f19bd2bf23405891ed5;hb=b83f62e0a9b4ca58b47749eec43b34f0ea04cfbb;hp=183641ba99152fc256caac622dae28425d0d4290;hpb=b0ffeb7eeb21920842382c302ca15ec0d758e9b6;p=tinc diff --git a/src/mingw/device.c b/src/mingw/device.c index 183641ba..03a1d48c 100644 --- a/src/mingw/device.c +++ b/src/mingw/device.c @@ -1,7 +1,7 @@ /* device.c -- Interaction with Windows tap driver in a MinGW environment Copyright (C) 2002-2005 Ivo Timmermans, - 2002-2014 Guus Sliepen + 2002-2022 Guus Sliepen This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -45,9 +45,7 @@ char *device = NULL; char *iface = NULL; static const char *device_info = "Windows tap device"; -extern char *myport; - -static void device_issue_read() { +static void device_issue_read(void) { int status; for(;;) { @@ -71,6 +69,9 @@ static void device_issue_read() { } static void device_handle_read(void *data, int flags) { + (void)data; + (void)flags; + DWORD len; if(!GetOverlappedResult(device_handle, &device_read_overlapped, &len, FALSE)) { @@ -105,8 +106,8 @@ static bool setup_device(void) { int err; - get_config_string(lookup_config(config_tree, "Device"), &device); - get_config_string(lookup_config(config_tree, "Interface"), &iface); + get_config_string(lookup_config(&config_tree, "Device"), &device); + get_config_string(lookup_config(&config_tree, "Interface"), &iface); if(device && iface) { logger(DEBUG_ALWAYS, LOG_WARNING, "Warning: both Device and Interface specified, results may not be as expected"); @@ -300,6 +301,7 @@ static void close_device(void) { } static bool read_packet(vpn_packet_t *packet) { + (void)packet; return false; }