]> Git Repo - qemu.git/commitdiff
vnc: g_realloc() can't fail, bury dead error handling
authorMarkus Armbruster <[email protected]>
Wed, 4 Feb 2015 10:26:06 +0000 (11:26 +0100)
committerMichael Tokarev <[email protected]>
Tue, 10 Feb 2015 06:27:20 +0000 (09:27 +0300)
Signed-off-by: Markus Armbruster <[email protected]>
Reviewed-by: Eric Blake <[email protected]>
Reviewed-by: Gonglei <[email protected]>
Reviewed-by: Thomas Huth <[email protected]>
Signed-off-by: Michael Tokarev <[email protected]>
ui/vnc.c

index a742c9071ce74fc4c30b3e31c1cec8cb39e6a02e..02552ee27b26bde1812e1f9a0403f08baf06f45e 100644 (file)
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -659,10 +659,6 @@ void buffer_reserve(Buffer *buffer, size_t len)
     if ((buffer->capacity - buffer->offset) < len) {
         buffer->capacity += (len + 1024);
         buffer->buffer = g_realloc(buffer->buffer, buffer->capacity);
-        if (buffer->buffer == NULL) {
-            fprintf(stderr, "vnc: out of memory\n");
-            exit(1);
-        }
     }
 }
 
This page took 0.029023 seconds and 4 git commands to generate.