btrbk: fix regression: undefined array reference when no received_uuid present

fixes #239 (@ian-kelling)
pull/219/merge
Axel Burri 2018-06-25 13:30:14 +02:00
parent 211943d4af
commit a0f6b55d28
1 changed files with 3 additions and 3 deletions

2
btrbk
View File

@ -2881,7 +2881,7 @@ sub _receive_target_nodes($$)
push(@match, @{ $received_uuid_hash->{$uuid} // [] }); # match src.uuid == target.received_uuid push(@match, @{ $received_uuid_hash->{$uuid} // [] }); # match src.uuid == target.received_uuid
if($received_uuid) { if($received_uuid) {
push(@match, $uuid_hash->{$received_uuid} ); # match src.received_uuid == target.uuid push(@match, $uuid_hash->{$received_uuid} ); # match src.received_uuid == target.uuid
push(@match, @{ $received_uuid_hash->{$received_uuid} }); # match src.received_uuid == target.received_uuid push(@match, @{ $received_uuid_hash->{$received_uuid} // [] }); # match src.received_uuid == target.received_uuid
} }
@ret = grep($_->{readonly}, @match); @ret = grep($_->{readonly}, @match);