mirror of
https://github.com/moparisthebest/pacman
synced 2025-03-01 01:41:52 -05:00
lib/util: modify entry_prefix, not prefix
Modifying prefix caused tmp directories to be left behind after running scriptlets, and the path '/' to be passed to _alpm_rmrf. Broken in f01c6f. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
parent
002d2fda7a
commit
0f4aaeee42
@ -300,7 +300,7 @@ int _alpm_unpack(pmhandle_t *handle, const char *archive, const char *prefix,
|
|||||||
/* If specific files were requested, skip entries that don't match. */
|
/* If specific files were requested, skip entries that don't match. */
|
||||||
if(list) {
|
if(list) {
|
||||||
char *entry_prefix = strdup(entryname);
|
char *entry_prefix = strdup(entryname);
|
||||||
char *p = strstr(prefix,"/");
|
char *p = strstr(entry_prefix,"/");
|
||||||
if(p) {
|
if(p) {
|
||||||
*(p+1) = '\0';
|
*(p+1) = '\0';
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user