diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2020-11-02 13:52:47 +0100 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2020-11-02 13:52:47 +0100 |
commit | 78bad1436ea141bd0464682ff8a729a80ee6cf79 (patch) | |
tree | a9e0831a1e34e7ec6dbe526b94b5e8ca79866cfe /api/adapter.c | |
parent | api: serialize driver installation (diff) | |
download | wintun-78bad1436ea141bd0464682ff8a729a80ee6cf79.tar.xz wintun-78bad1436ea141bd0464682ff8a729a80ee6cf79.zip |
api: statically compile devpkey constants
I don't like this solution, but I don't see much other choice. It's not
in uuid.lib or anywhere like that.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'api/adapter.c')
-rw-r--r-- | api/adapter.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/api/adapter.c b/api/adapter.c index d996d99..ca0b823 100644 --- a/api/adapter.c +++ b/api/adapter.c @@ -25,6 +25,8 @@ #include <SetupAPI.h> #include <Shlwapi.h> #include <wchar.h> +#include <initguid.h> /* Keep these two at bottom in this order, so that we only generate extra GUIDs for devpkey. The other keys we'll get from uuid.lib like usual. */ +#include <devpkey.h> #pragma warning(disable : 4221) /* nonstandard: address of automatic in initializer */ @@ -1291,10 +1293,6 @@ CreateAdapter( goto cleanupTcpipInterfaceRegKey; } - /* TODO: This GUIDs is in devpkey.h, but we can't link to it? Which dll? */ - static const DEVPROPKEY DEVPKEY_Device_ProblemStatus = { - { 0x4340a6c5, 0x93fa, 0x4706, { 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7 } }, 12 - }; DEVPROPTYPE PropertyType; for (int Tries = 0; Tries < 1000; ++Tries) { |