diff options
Diffstat (limited to 'unmaintained/cuetools/cuetag-fix_spaces.patch')
-rw-r--r-- | unmaintained/cuetools/cuetag-fix_spaces.patch | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/unmaintained/cuetools/cuetag-fix_spaces.patch b/unmaintained/cuetools/cuetag-fix_spaces.patch new file mode 100644 index 0000000000..f240e9d375 --- /dev/null +++ b/unmaintained/cuetools/cuetag-fix_spaces.patch @@ -0,0 +1,46 @@ +From 21ee6cc40f02693928efbc4f3beeb681950c16b5 Mon Sep 17 00:00:00 2001 +From: Svend Sorensen <svend@ciffer.net> +Date: Sat, 23 Nov 2013 17:23:01 -0800 +Subject: [PATCH] cuetag: Fix handling of spaces in file names + +Fixes #14 +--- + src/tools/cuetag.sh | 9 ++++----- + 1 file changed, 4 insertions(+), 5 deletions(-) + +diff --git a/src/tools/cuetag.sh b/src/tools/cuetag.sh +index f26fa20..448920f 100755 +--- a/src/tools/cuetag.sh ++++ b/src/tools/cuetag.sh +@@ -182,16 +182,15 @@ main() + ntrack=$(cueprint -d '%N' "$cue_file") + trackno=1 + +- FILES= FIELDS= ++ NUM_FILES=0 FIELDS= + for arg in "$@"; do + case "$arg" in +- *.*) FILES="$FILES $arg";; ++ *.*) NUM_FILES=$(expr $NUM_FILES + 1);; + *) FIELDS="$FIELDS $arg";; + esac + done + +- set -- $FILES +- if [ $# -ne $ntrack ]; then ++ if [ $NUM_FILES -ne $ntrack ]; then + echo "warning: number of files does not match number of tracks" + fi + +@@ -209,7 +208,7 @@ main() + *.[Tt][Xx][Tt]) + vorbis $trackno "$file" + ;; +- *) ++ *.*) + echo "$file: uknown file type" + ;; + esac +-- +1.8.5.1 + |