mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-20 16:51:37 +00:00
pb: Don't crash when showing empty repeated field
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
parent
54f4f889a5
commit
8f7bae2cfc
1 changed files with 2 additions and 1 deletions
|
|
@ -184,7 +184,8 @@ static size_t pb_show_prepare_field_context(const ProtobufCFieldDescriptor *fd,
|
|||
break;
|
||||
case PROTOBUF_C_TYPE_MESSAGE:
|
||||
ctl->arg = (void *)fd->descriptor;
|
||||
field->data = (void *)(*(long *)field->data);
|
||||
if (field->data)
|
||||
field->data = (void *)(*(long *)field->data);
|
||||
case PROTOBUF_C_TYPE_STRING:
|
||||
fsize = sizeof (void *);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue