sd_bus_message_read(m, "x", &x);</programlisting>
+ <para>Read a boolean value:</para>
+
+ <programlisting>sd_bus_message *m;
+int x; /* Do not use C99 'bool' type here, it's typically smaller
+ in memory and would cause memory corruption */
+
+sd_bus_message_read(m, "b", &x);</programlisting>
+
<para>Read all types of integers:</para>
<programlisting>uint8_t y;
<entry><literal>b</literal></entry>
<entry><constant>SD_BUS_TYPE_BOOLEAN</constant></entry>
<entry>boolean</entry>
- <entry><type>int *</type></entry>
+ <entry><type>int *</type> (NB: not <type>bool *</type>)</entry>
</row>
<row>