diff options
author | waker <wakeroid@gmail.com> | 2012-08-05 12:04:48 +0200 |
---|---|---|
committer | waker <wakeroid@gmail.com> | 2012-08-05 12:04:48 +0200 |
commit | 99730a4ce8e554147c01fc976e5c862ce01ee1e0 (patch) | |
tree | be67367399a71da248f5f0386bd79cdda79a6743 /playlist.c | |
parent | 7bcfb80083304ae771b49db1c97f1e54e04a51b2 (diff) |
skip utf8 bom in cuesheets
Diffstat (limited to 'playlist.c')
-rw-r--r-- | playlist.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -998,6 +998,10 @@ plt_process_cue_track (playlist_t *playlist, const char *fname, playItem_t **pre playItem_t * plt_insert_cue_from_buffer (playlist_t *playlist, playItem_t *after, playItem_t *origin, const uint8_t *buffer, int buffersize, int numsamples, int samplerate) { LOCK; + if (buffersize >= 3 && buffer[0] == 0xef && buffer[1] == 0xbb && buffer[2] == 0xbf) { + buffer += 3; + buffersize -= 3; + } playItem_t *ins = after; trace ("plt_insert_cue_from_buffer numsamples=%d, samplerate=%d\n", numsamples, samplerate); char albumperformer[256] = ""; |