diff options
Diffstat (limited to 'urpm')
-rw-r--r-- | urpm/select.pm | 4 | ||||
-rw-r--r-- | urpm/sys.pm | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/urpm/select.pm b/urpm/select.pm index 978f88bb..cc96d9d5 100644 --- a/urpm/select.pm +++ b/urpm/select.pm @@ -262,7 +262,7 @@ sub cooked_prefer { @{$urpm->{prefer_regexps}}; } -sub sort_choices { +sub get_preferred { my ($urpm, $choices, $cmdline_prefer) = @_; my @prefer; @@ -278,7 +278,7 @@ sub sort_choices { $urpm->{log}("preferring $prefer_s over $other_s"); } } - (@prefer, @l); + (\@prefer, \@l); } #- find packages to remove. diff --git a/urpm/sys.pm b/urpm/sys.pm index 612c9ed6..da7736d9 100644 --- a/urpm/sys.pm +++ b/urpm/sys.pm @@ -16,7 +16,7 @@ use POSIX (); sub get_packages_list { my ($file, $o_extra) = @_; my @l = split(/,/, $o_extra || ''); - if (open(my $f, '<', $file)) { + if ($file && open(my $f, '<', $file)) { push @l, <$f>; } [ grep { $_ } map { |