Searched hist:"6 a150995d486013221361cddb5ae6189afb0cef5" (Results 1 – 1 of 1) sorted by relevance
/openbmc/qemu/util/ |
H A D | hbitmap.c | diff 6a150995d486013221361cddb5ae6189afb0cef5 Wed Feb 05 05:20:32 CST 2020 Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> hbitmap: assert that we don't create bitmap larger than INT64_MAX
We have APIs which returns signed int64_t, to be able to return error. Therefore we can't handle bitmaps with absolute size larger than (INT64_MAX+1). Still, keep maximum to be INT64_MAX which is a bit safer.
Note, that bitmaps are used to represent disk images, which can't exceed INT64_MAX anyway.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: John Snow <jsnow@redhat.com> Message-id: 20200205112041.6003-2-vsementsov@virtuozzo.com Signed-off-by: John Snow <jsnow@redhat.com>
|