upstream fix; submitted by maintainer Han Boetes <han@linux-mandrake.org>

This commit is contained in:
naddy 2003-05-23 20:07:47 +00:00
parent 5bb78b646a
commit 5b97be2c6b

View File

@ -1,6 +1,6 @@
$OpenBSD: patch-vlorb,v 1.2 2003/05/14 23:37:49 naddy Exp $
--- vlorb.orig Tue May 13 06:50:37 2003
+++ vlorb Wed May 14 15:54:39 2003
$OpenBSD: patch-vlorb,v 1.3 2003/05/23 20:07:47 naddy Exp $
--- vlorb.orig Fri May 23 18:29:43 2003
+++ vlorb Fri May 23 18:30:05 2003
@@ -1,4 +1,4 @@
-#!/usr/bin/env perl
+#!/usr/bin/perl
@ -16,3 +16,38 @@ $OpenBSD: patch-vlorb,v 1.2 2003/05/14 23:37:49 naddy Exp $
# 1 = Use bitrate mode, 0 = use quality mode for ogg encoding.
$config{use_bitrate} = 0;
@@ -312,7 +312,7 @@ sub mk_album_directory() {
my ($artist, $disctitle, $mask) = @_;
my $albumdir;
- if ($global{singleartist}) {
+ if (($global{singleartist}) && ($disctitle ne $config{unknown})) {
my @dname = split(//, $mask);
for (@dname) {
($_ ne 'A' && $_ ne 'D') && do { &error('error in dirmask: ' . $mask) };
@@ -332,7 +332,7 @@ sub mk_album_directory() {
$dirname = $dirname . $config{filemask_seperator} . $dname[$i] if ($dname[$i]);
$i++;
}
- $albumdir = $dirname;
+ $albumdir = $dirname;
} else {
$albumdir = $disctitle;
}
@@ -733,11 +733,11 @@ sub vlorb() {
&msg("\n") if $config{show_progress};
# escape double quotes in strings
- $tracktitle =~ s/"/\\"/g;
- $disctitle =~ s/"/\\"/g;
- $artist =~ s/"/\\"/g;
- $genre =~ s/"/\\"/g;
- $filename =~ s/"/\\"/g;
+ $tracktitle =~ s/"/\\"/g if ($tracktitle);
+ $disctitle =~ s/"/\\"/g if ($disctitle);
+ $artist =~ s/"/\\"/g if ($artist);
+ $genre =~ s/"/\\"/g if ($genre);
+ $filename =~ s/"/\\"/g if ($filename);
my $bq = "-q $config{quality}";
$bq = "-b $config{bitrate}" if ($config{use_bitrate});