Skip to content

Commit c933f6c

Browse files
sciuriusbriandfoy
authored andcommitted
default value for $options in patch (#991)
1 parent 9ff5309 commit c933f6c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

bin/patch

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,7 @@ sub bless {
375375
my $class = "Patch::\u$type";
376376

377377
my ($options, $garbage) = @{$_[0]}{'options', 'garbage'};
378+
$options //= [];
378379

379380
# New hunk, same patch.
380381
$_[0]{hunk}++, return 1 if $_[0]->isa($class) && ! @$garbage;

0 commit comments

Comments
 (0)