tests: Fix logic to not have possible NULL deref
tests: Fix logic to not have possible NULL deref

It's possible that virBitmapNewString returns NULL with an error
string (and not an allocation failure that would abort); however, if
virBitmapToString is called with a NULL @bitmap, then it will fail
in an ugly manner. So rather than have if (!map && !str) logic, split
the checks for each variable.

Found by Coverity

Signed-off-by: John Ferlan <87558058f6f829e5ec976c8ef960720af4ff9c7d@redhat.com>
Reviewed-by: Daniel P. Berrangé <bb938cf255e055ff3507f2627d214e8e62118fcf@redhat.com>

jfehlig/libvirt,nertpinx/libvirt,jardasgit/libvirt,zippy2/libvirt,fabianfreyer/libvirt,nertpinx/libvirt,crobinso/libvirt,zippy2/libvirt,jfehlig/libvirt,crobinso/libvirt,jfehlig/libvirt,fabianfreyer/libvirt,olafhering/libvirt,fabianfreyer/libvirt,libvirt/libvirt,olafhering/libvirt,nertpinx/libvirt,nertpinx/libvirt,nertpinx/libvirt,jardasgit/libvirt,libvirt/libvirt,libvirt/libvirt,crobinso/libvirt,fabianfreyer/libvirt,jardasgit/libvirt,crobinso/libvirt,jardasgit/libvirt,zippy2/libvirt,zippy2/libvirt,libvirt/libvirt,olafhering/libvirt,jfehlig/libvirt,jardasgit/libvirt,olafhering/libvirt,fabianfreyer/libvirt