advertising: parse_[min|max]_interval: reset value if iter is NULL

Set property to its default value (as done in all other methods listed
in parsers[]).
This commit is contained in:
Christian Eggers 2022-09-23 16:57:31 +02:00 committed by Luiz Augusto von Dentz
parent abfb3a807c
commit a18d66862d

View File

@ -1120,8 +1120,10 @@ static bool parse_max_interval(DBusMessageIter *iter,
if (!(g_dbus_get_flags() & G_DBUS_FLAG_ENABLE_EXPERIMENTAL))
return true;
if (!iter)
if (!iter) {
client->max_interval = 0;
return false;
}
if (dbus_message_iter_get_arg_type(iter) != DBUS_TYPE_UINT32)
return false;