diff options
author | Francois Pons <fpons@mandriva.com> | 2002-11-07 15:52:48 +0000 |
---|---|---|
committer | Francois Pons <fpons@mandriva.com> | 2002-11-07 15:52:48 +0000 |
commit | d386aea106753bb930ab65b9bfd434e8e75f2c84 (patch) | |
tree | 3c6a21356a3dc78917ec4cc5c79ead7a9008ae6c /urpm.pm | |
parent | 730c95d0fc3972285b60cbb5ac64ec4bd03c875e (diff) | |
download | urpmi-d386aea106753bb930ab65b9bfd434e8e75f2c84.tar urpmi-d386aea106753bb930ab65b9bfd434e8e75f2c84.tar.gz urpmi-d386aea106753bb930ab65b9bfd434e8e75f2c84.tar.bz2 urpmi-d386aea106753bb930ab65b9bfd434e8e75f2c84.tar.xz urpmi-d386aea106753bb930ab65b9bfd434e8e75f2c84.zip |
4.0-24mdk
Diffstat (limited to 'urpm.pm')
-rw-r--r-- | urpm.pm | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -975,8 +975,9 @@ sub update_media { #- and check hdlist has not be named very strangely... if ($medium->{hdlist} ne 'list') { my $local_list = $medium->{with_hdlist} =~ /hd(list.*)\.cz$/ ? $1 : 'list'; + #- always delete a remaining list file in cache. + unlink "$urpm->{cachedir}/partial/list"; if (-s "$dir/$local_list") { - unlink "$urpm->{cachedir}/partial/list"; $urpm->{log}(_("copying source list of \"%s\"...", $medium->{name})); system("cp", "-pR", "$dir/$local_list", "$urpm->{cachedir}/partial/list") ? $urpm->{log}(_("...copying failed")) : $urpm->{log}(_("...copying done")); @@ -1238,8 +1239,11 @@ sub update_media { close LIST; #- check if at least something has been written into list file. - -s "$urpm->{cachedir}/partial/$medium->{list}" > 32 or - $error = 1, $urpm->{error}(_("nothing written in list file for \"%s\"", $medium->{name})); + if (-s "$urpm->{cachedir}/partial/$medium->{list}" > 32) { + $urpm->{log}(_("writing list file for medium \"%s\"", $medium->{name})); + } else { + $error = 1, $urpm->{error}(_("nothing written in list file for \"%s\"", $medium->{name})); + } } } |