diff options
author | zhuyaliang <[email protected]> | 2023-05-10 15:11:42 +0800 |
---|---|---|
committer | Luke from DC <[email protected]> | 2023-05-14 11:02:52 +0000 |
commit | 77bc1e4361f2f5fe2f94615b675e6c454e6f8748 (patch) | |
tree | 97dccc16ca14c4a56cd5b4175b211b88ff68e875 /src | |
parent | 4a7a10a0eac6ee5f54b46f2f3f26d4b9693b4d9c (diff) | |
download | engrampa-77bc1e4361f2f5fe2f94615b675e6c454e6f8748.tar.bz2 engrampa-77bc1e4361f2f5fe2f94615b675e6c454e6f8748.tar.xz |
Fix failure to extract multiple files
Diffstat (limited to 'src')
-rw-r--r-- | src/glib-utils.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/glib-utils.c b/src/glib-utils.c index c7cb78c..2ac5670 100644 --- a/src/glib-utils.c +++ b/src/glib-utils.c @@ -510,6 +510,9 @@ _g_path_get_base_name (const char *path, if (junk_paths) return _g_path_get_file_name (path); + if (base_dir == NULL) + return (path[0] == '/') ? path + 1 : path; + base_dir_len = strlen (base_dir); if (strlen (path) < base_dir_len) return NULL; |