cue tokens are case-insensitive

This commit is contained in:
bparker06 2019-08-01 19:16:18 -04:00 committed by GitHub
parent 9022565efe
commit 56ef7eb229
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 5 deletions

View File

@ -489,7 +489,7 @@ int cue_find_track(const char *cue_path, bool first,
while (get_token(fd, tmp_token, MAX_TOKEN_LEN) > 0)
{
if (string_is_equal(tmp_token, "FILE"))
if (string_is_equal_noncase(tmp_token, "FILE"))
{
/* Set last index to last EOF */
if (file_size != -1)
@ -512,14 +512,14 @@ int cue_find_track(const char *cue_path, bool first,
get_token(fd, tmp_token, MAX_TOKEN_LEN);
}
else if (string_is_equal(tmp_token, "TRACK"))
else if (string_is_equal_noncase(tmp_token, "TRACK"))
{
get_token(fd, tmp_token, MAX_TOKEN_LEN);
get_token(fd, tmp_token, MAX_TOKEN_LEN);
is_data = !string_is_equal(tmp_token, "AUDIO");
is_data = !string_is_equal_noncase(tmp_token, "AUDIO");
++track;
}
else if (string_is_equal(tmp_token, "INDEX"))
else if (string_is_equal_noncase(tmp_token, "INDEX"))
{
int m, s, f;
get_token(fd, tmp_token, MAX_TOKEN_LEN);
@ -595,7 +595,7 @@ bool cue_next_file(intfstream_t *fd,
while (get_token(fd, tmp_token, MAX_TOKEN_LEN) > 0)
{
if (string_is_equal(tmp_token, "FILE"))
if (string_is_equal_noncase(tmp_token, "FILE"))
{
get_token(fd, tmp_token, MAX_TOKEN_LEN);
fill_pathname_join(path, cue_dir, tmp_token, (size_t)max_len);