Commit b0d79a32 authored by Raphaël Hertzog's avatar Raphaël Hertzog

Dpkg::Source::Functions::is_binary(): localize $_ to avoid side-effects

Without this local($_) the function could modify the $_ variable as used
by the caller.
parent c4848828
......@@ -102,6 +102,7 @@ sub is_binary($) {
'to_pipe' => \$diffgen
);
my $result = 0;
local $_;
while (<$diffgen>) {
if (m/^(?:binary|[^-+\@ ].*\bdiffer\b)/i) {
$result = 1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment