Be more strict about message size mismatches.

This commit is contained in:
Luiz Augusto von Dentz 2008-12-19 19:41:39 -03:00 committed by Johan Hedberg
parent ef91427a2e
commit c4596b6ceb

View File

@ -1128,6 +1128,11 @@ static gboolean client_cb(GIOChannel *chan, GIOCondition cond, gpointer data)
debug("Audio API: %s <- %s", type, name);
if (msghdr->length != len) {
error("Invalid message: length mismatch");
goto failed;
}
switch (msghdr->name) {
case BT_GET_CAPABILITIES:
handle_getcapabilities_req(client,