diff options
author | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2004-11-18 15:19:26 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2004-11-18 15:19:26 +0000 |
commit | d30d087596c8b84cde4a598c3527e1f8e75d2368 (patch) | |
tree | 338d5680ebf002da7d36ac82f0c0d602d3928abe | |
parent | 413bd7ec8289df17e4b0ae20170ec2047df40f39 (diff) | |
download | urpmi-d30d087596c8b84cde4a598c3527e1f8e75d2368.tar urpmi-d30d087596c8b84cde4a598c3527e1f8e75d2368.tar.gz urpmi-d30d087596c8b84cde4a598c3527e1f8e75d2368.tar.bz2 urpmi-d30d087596c8b84cde4a598c3527e1f8e75d2368.tar.xz urpmi-d30d087596c8b84cde4a598c3527e1f8e75d2368.zip |
Requires that a magic line appears in reconfig.urpmi (bug #12384)
-rw-r--r-- | urpm.pm | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -837,6 +837,9 @@ sub reconfig_urpmi { my $reconfigured = 0; open my $fh, $rfile or return undef; $urpm->{log}(N("reconfiguring urpmi for media \"%s\"", $name)); + #- the first line of reconfig.urpmi must be magic, to be sure it's not an error file + my $magic = <$fh>; + $magic =~ /^# this is an urpmi reconfiguration file/ or return undef; while (<$fh>) { chomp; s/^\s*//; s/#.*$//; s/\s*$//; |