mirror of
https://github.com/msgpack/msgpack-c.git
synced 2025-10-13 06:44:15 +02:00
c: fixes msgpack_zbuffer_flush: error checking
This commit is contained in:
@@ -125,7 +125,9 @@ char* msgpack_zbuffer_flush(msgpack_zbuffer* zbuf)
|
||||
case Z_STREAM_END:
|
||||
return zbuf->data;
|
||||
case Z_OK:
|
||||
msgpack_zbuffer_expand(zbuf);
|
||||
if(!msgpack_zbuffer_expand(zbuf)) {
|
||||
return NULL;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
return NULL;
|
||||
|
Reference in New Issue
Block a user