Explorar o código

Whine less when ignoring bad downloads

Zachary Kotlarek %!s(int64=12) %!d(string=hai) anos
pai
achega
fab665d1f7
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      transmission.pl

+ 3 - 1
transmission.pl

@@ -186,7 +186,9 @@ foreach my $tor (@{$torrents}) {
 				print STDERR 'Torrent stored successfully: ' . $tor->{'name'} . "\n";
 			}
 		} elsif (defined($result) && $result == -1) {
-			print STDERR 'Deleting bad torrent: ' . $tor->{'name'} . "\n";
+			if ($DEBUG) {
+				print STDERR 'Deleting bad torrent: ' . $tor->{'name'} . "\n";
+			}
 			last;
 		} else {
 			print STDERR 'Error storing file "' . basename($file) . '" from torrent: ' . $tor->{'name'} . "\n";