block-qdict: Pacify Coverity after commit f1b34a248e9
commit17e9aa3f220df64fc288a175dbd62324e92d850c
authorMarkus Armbruster <armbru@redhat.com>
Tue, 26 Jun 2018 08:05:45 +0000 (26 10:05 +0200)
committerKevin Wolf <kwolf@redhat.com>
Fri, 29 Jun 2018 12:20:56 +0000 (29 14:20 +0200)
tree604262fa209b8f2f5a84eca9747ee3b3e6c75964
parent609ef9f451759151d0bfe7c3843410ab94d68f18
block-qdict: Pacify Coverity after commit f1b34a248e9

Commit f1b34a248e9 replaced less-than-obvious test in
qdict_flatten_qdict() by the obvious one.  Sadly, it made something
else non-obvious: the fact that @new_key passed to qdict_put_obj()
can't be null, because that depends on the function's precondition
(target == qdict) == !prefix.

Tweak the function some more to help Coverity and human readers alike.

Fixes: CID 1393620
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
qobject/block-qdict.c