]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
tests: bhyve: use bitwise shift when defining flags
authorJán Tomko <jtomko@redhat.com>
Tue, 24 Nov 2020 14:25:27 +0000 (15:25 +0100)
committerJán Tomko <jtomko@redhat.com>
Wed, 8 Sep 2021 13:13:12 +0000 (15:13 +0200)
Although I'm sure we all know the powers of two by heart now,
this is the prevalent style for flag defition.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
tests/bhyveargv2xmltest.c

index e86c9e3b10d4d2677c9d19f8bf85b355598df146..2ccc1379b9a5816043c07074326fa4c1c596e661 100644 (file)
@@ -17,9 +17,9 @@
 static bhyveConn driver;
 
 typedef enum {
-    FLAG_EXPECT_FAILURE     = 1,
-    FLAG_EXPECT_PARSE_ERROR = 2,
-    FLAG_EXPECT_WARNING     = 4,
+    FLAG_EXPECT_FAILURE     = 1 << 0,
+    FLAG_EXPECT_PARSE_ERROR = 1 << 1,
+    FLAG_EXPECT_WARNING     = 1 << 2,
 } virBhyveArgv2XMLTestFlags;
 
 static int