From 04c02796bd371e65f81a92b853658b8fbadb7ad5 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 9 May 2015 15:26:47 +0200 Subject: path: make mp_path_join accept normal C strings Instead of bstr. Most callers of this function do not need bstr. The bstr version of this function is now mp_path_join_bstr(). --- sub/find_subfiles.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sub') diff --git a/sub/find_subfiles.c b/sub/find_subfiles.c index 10dd479a07..bdeef0fadc 100644 --- a/sub/find_subfiles.c +++ b/sub/find_subfiles.c @@ -188,7 +188,7 @@ static void append_dir_subtitles(struct mpv_global *global, if (prio) { prio += prio; - char *subpath = mp_path_join(*slist, path, dename); + char *subpath = mp_path_join_bstr(*slist, path, dename); if (mp_path_exists(subpath)) { MP_GROW_ARRAY(*slist, *nsub); struct subfn *sub = *slist + (*nsub)++; @@ -256,8 +256,8 @@ struct subfn *find_external_files(struct mpv_global *global, const char *fname) // Load subtitles in dirs specified by sub-paths option if (opts->sub_paths) { for (int i = 0; opts->sub_paths[i]; i++) { - char *path = mp_path_join(slist, mp_dirname(fname), - bstr0(opts->sub_paths[i])); + char *path = mp_path_join_bstr(slist, mp_dirname(fname), + bstr0(opts->sub_paths[i])); append_dir_subtitles(global, &slist, &n, bstr0(path), fname, 0); } } -- cgit v1.2.3