mirror of
https://github.com/checkpoint-restore/criu
synced 2025-08-30 05:48:05 +00:00
protobuf: skip show of zero-size repeated fields
Print "<empty>" message for such filed instead. #2425 Signed-off-by: Andrew Vagin <avagin@parallels.com> Signed-off-by: Stanislav Kinsbursky <skinsbursky@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
parent
c237a720b1
commit
eee14340e3
@ -405,6 +405,11 @@ static void pb_show_repeated(pb_pr_ctl_t *ctl, int nr_fields, pb_pr_show_t show,
|
||||
unsigned long counter;
|
||||
int done;
|
||||
|
||||
if (nr_fields == 0) {
|
||||
pr_msg("<empty>");
|
||||
return;
|
||||
}
|
||||
|
||||
field->count = nr_fields;
|
||||
done = show(field);
|
||||
if (done)
|
||||
|
Loading…
x
Reference in New Issue
Block a user