Public bug reported:

Binary package hint: pacpl

While using pacpl to convert a batch of .flac files to .m4a, I noticed
it failing on a randomly-selected set of music files. Closer examination
revealed that they were all classical music pieces whose tags I had
gotten from MusicBrainz, and that the files that were failing were the
pieces whose title contained double-quotes with a space character inside
them. For example, the Mozart album at http://musicbrainz.org/release
/45179fbc-62c0-4992-9511-c61310dc0f9f.html (title too long to copy here)
has the following track titles:

...
Track 7: Mass No. 15 for Soloists, Chorus & Orchestra in C major, K. 317 
"Coronation Mass": VI. "Agnus Dei"
Track 8: Missa solemnis No. 16 for Soloists, Chorus & Orchestra in C major, K. 
337: I. "Kyrie"
...

After much poking at the problem, I have figured out what is happening.
After decompressing the .flac files to .wav, pacpl is calling the
following commands to encode the M4A files:

For track 7:

faac --title "Mass No. 15 for Soloists, Chorus & Orchestra in C major,
K. 317 "Coronation Mass": VI. "Agnus Dei"" --track "7" --artist
"Wolfgang Amadeus Mozart" --album "Masses: Mass in C minor K. 427,
Coronation Mass in C major K. 317, Missa Solemnis in C major K. 337,
Kyrie in D minor K. 341 (Kölner Kammerchor & Collegium Cartusianum feat.
conductor: Peter Neumann)" --comment "" --year "1990-01-01" --genre
"Classical"  -w -q 100
"/home/rmunn/tmp/music/classical/Masses/02.07.19776.wav" -o
"/home/rmunn/tmp/music/classical/Masses/02.07.m4a"

For track 8:

faac --title "Missa solemnis No. 16 for Soloists, Chorus & Orchestra in
C major, K. 337: I. "Kyrie"" --track "8" --artist "Wolfgang Amadeus
Mozart" --album "Masses: Mass in C minor K. 427, Coronation Mass in C
major K. 317, Missa Solemnis in C major K. 337, Kyrie in D minor K. 341
(Kölner Kammerchor & Collegium Cartusianum feat. conductor: Peter
Neumann)" --comment "" --year "1990-01-01" --genre "Classical"  -w -q
100 "/home/rmunn/tmp/music/classical/Masses/02.08.19813.wav" -o
"/home/rmunn/tmp/music/classical/Masses/02.08.m4a"

Track 8 works, but track 7 fails with the error message "Cannot encode
several input files to one output file."

Because the double-quotes in the title string aren't quoted or
backslash-escaped, the shell sees them as the end of the title string.
If the double-quote characters contain just a single word (as in track
8, where it's the word "Kyrie") then this doesn't matter, as the shell
still sees that whole title (from "Missa solemnis" to the word "Kyrie")
as a single string. But in track 7, the parameter "Mass No. 15 for
Soloists, Chorus & Orchestra in C major, K. 317 "Coronation Mass": VI.
"Agnus Dei"" gets interpreted by the string as:

First parameter: "Mass No. 15 for Soloists, Chorus & Orchestra in C major, K. 
317 "Coronation
Second parameter: Mass": VI. "Agnus
Third parameter: Dei""

And thus, faac thinks it's being asked to encode several input files
(one file called Mass": VI. "Agnus and another file called Dei"") with
just a single output file, and so it gives up.

Since the original files that triggered this bug for me are copyrighted,
I can't upload them here. I have, however, managed to reproduce this bug
using a .flac file I created myself (from a Creative-Commons licensed
file downloaded from www.freesound.org), so I'll upload that file to
this bug report so that the bug can be reproduced.

** Affects: pacpl (Ubuntu)
     Importance: Undecided
         Status: New

-- 
pacpl can't handle double-quote characters in title tags
https://bugs.launchpad.net/bugs/533111
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to