]> git.ipfire.org Git - thirdparty/open-vm-tools.git/commitdiff
Common header file change not applicable to open-vm-tools.
authorOliver Kurth <okurth@vmware.com>
Mon, 30 Sep 2019 23:24:27 +0000 (16:24 -0700)
committerOliver Kurth <okurth@vmware.com>
Mon, 30 Sep 2019 23:24:27 +0000 (16:24 -0700)
open-vm-tools/lib/include/vm_basic_defs.h

index aa9396fe45dead330afe134e60d6e0db8215b252..3c82e04074b2e29378c9a7f0f1b7061109ece628 100644 (file)
@@ -840,4 +840,15 @@ typedef int pid_t;
 #define END_PTR_TO_ALIGNED_VAR \
    } while (0)
 
+
+/*
+ * -Wswitch means that when you pass switch an enum that it's looking for
+ * all values from that enum, and only that enum, to be accounted for.
+ * "default:;" is fine for catching values you don't care about. But today
+ * we have a bunch of code that uses internal and external enum values, or
+ * in other words combines two enums into a single variable. This cast is
+ * the workaround, but we really need to fix this mess.
+ */
+#define UNCHECKED_SWITCH__FIXME(x) switch ((uint64)(x))
+
 #endif // ifndef _VM_BASIC_DEFS_H_