libxenguest: Add another range check to dom restore.

Signed-off-by: Keir Fraser <keir@xensource.com>
This commit is contained in:
kfraser@localhost.localdomain committed 2007-06-21 12:10:01 +01:00
1 parent 284d8c4881
commit 5a07d757fb
1 file changed
+1 -1
+1 -1
View File
@@ -465,7 +465,7 @@ int xc_domain_restore(int xc_handle, int io_fd, uint32_t dom,
if ( j == 0 )
break; /* our work here is done */
if ( j > MAX_BATCH_SIZE )
if ( (j > MAX_BATCH_SIZE) || (j < 0) )
{
ERROR("Max batch size exceeded. Giving up.");
goto out;
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.