configfiles: refactor mp_get_playback_resume_config_filename()
This avoids duplicating fname when it is a URL.
This commit is contained in:
1 parent
a5fa862a44
commit
0bb1659cd6
1 file changed
+3
-1
@@ -215,7 +215,9 @@ static char *mp_get_playback_resume_config_filename(struct MPContext *mpctx,
|
||||
char *res = NULL;
|
||||
void *tmp = talloc_new(NULL);
|
||||
const char *path = NULL;
|
||||
if (opts->ignore_path_in_watch_later_config && !mp_is_url(bstr0(fname))) {
|
||||
if (mp_is_url(bstr0(fname))) {
|
||||
path = fname;
|
||||
} else if (opts->ignore_path_in_watch_later_config) {
|
||||
path = mp_basename(fname);
|
||||
} else {
|
||||
path = mp_normalize_path(tmp, fname);
|
||||
|
||||
Reference in new issue
Block a user