[daemon-fix] fixed querying about name information
[platform/upstream/dbus.git] / dbus / dbus-string-private.h
index 185515d..2e6de90 100644 (file)
@@ -24,6 +24,7 @@
 #ifndef DBUS_STRING_PRIVATE_H
 #define DBUS_STRING_PRIVATE_H
 
+#include <dbus/dbus-internals.h>
 #include <dbus/dbus-memory.h>
 #include <dbus/dbus-types.h>
 
@@ -50,6 +51,7 @@ typedef struct
   unsigned int   align_offset : 3; /**< str - align_offset is the actual malloc block */
 } DBusRealString;
 
+_DBUS_STATIC_ASSERT (sizeof (DBusRealString) == sizeof (DBusString));
 
 /**
  * @defgroup DBusStringInternals DBusString implementation details
@@ -73,6 +75,7 @@ typedef struct
  */
 #define DBUS_GENERIC_STRING_PREAMBLE(real) \
   do { \
+      (void) real; /* might be unused unless asserting */ \
       _dbus_assert ((real) != NULL); \
       _dbus_assert (!(real)->invalid); \
       _dbus_assert ((real)->len >= 0); \