]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
sd-bus: change "int" → "signed int" on bitfield
authorLennart Poettering <lennart@poettering.net>
Thu, 28 Mar 2019 08:26:50 +0000 (09:26 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 28 Mar 2019 18:07:51 +0000 (19:07 +0100)
Apparently by the C standard "int" bitfields can have any signedness
(unlike non-bitfield declarations which are "signed" if the signedness
is not specified).

Let's fix the LGTM warning about this hence and be explicit that we mean
"signed" here.

src/libsystemd/sd-bus/bus-internal.h

index 5d6cce01685814bbfd0504a1e13c8cff1a7f138f..d7fcb9329b91ce7b4235344db13cf3cccafe0377 100644 (file)
@@ -211,7 +211,7 @@ struct sd_bus {
         bool connected_signal:1;
         bool close_on_exit:1;
 
-        int use_memfd:2;
+        signed int use_memfd:2;
 
         void *rbuffer;
         size_t rbuffer_size;