We recommend disabling assertions in production builds of dbus, so it
is "cheap" to add them even in relatively fast-path locations.
Signed-off-by: Simon McVittie <smcv@collabora.com>
_dbus_assert_not_reached ("not a basic type");
break;
}
+
+ /* We had better still be in-bounds at this point (pointing either into
+ * the content of the string, or 1 past the logical length of the string) */
+ _dbus_assert (*pos <= _dbus_string_get_length (str));
}
/**
/* Skip the actual array data */
*pos = i + array_len;
+
+ /* We had better still be in-bounds at this point (pointing either into
+ * the content of the string, or 1 past the logical length of the string) */
+ _dbus_assert (*pos <= _dbus_string_get_length (str));
}
/**