mirror of
https://github.com/vgmstream/vgmstream.git
synced 2024-11-13 18:20:50 +01:00
Fix title segfault in Audacious
This commit is contained in:
parent
ce7972baa9
commit
c4d76869dc
@ -81,7 +81,7 @@ void vgmstream_get_title(char* buf, int buf_len, const char* filename, VGMSTREAM
|
||||
strncpy(buf, pos, buf_len);
|
||||
|
||||
/* name without extension */
|
||||
if (cfg->remove_extension) {
|
||||
if (cfg && cfg->remove_extension) {
|
||||
pos2 = strrchr(buf, '.');
|
||||
if (pos2 && strlen(pos2) < 15) /* too big extension = file name probably has a dot in the middle */
|
||||
pos2[0] = '\0';
|
||||
|
Loading…
Reference in New Issue
Block a user