mirror of
https://abf.rosa.ru/djam/rpm.git
synced 2025-02-23 10:23:04 +00:00
23 lines
824 B
Diff
23 lines
824 B
Diff
--- rpm-5.4.9/lib/psm.c.slash~ 2012-05-15 03:47:32.000000000 +0200
|
|
+++ rpm-5.4.9/lib/psm.c 2012-05-15 03:49:04.075347677 +0200
|
|
@@ -1463,11 +1463,15 @@ static rpmRC runTriggersLoop(rpmpsm psm,
|
|
ARGint_t vals;
|
|
|
|
depName = _free(depName);
|
|
- depName = (char *) xmalloc(nName + 1 + 1);
|
|
- (void) stpcpy(depName, Name);
|
|
- /* XXX re-add the pesky trailing '/' to dirnames. */
|
|
- depName[nName] = (tagno == RPMTAG_DIRNAMES ? '/' : '\0');
|
|
- depName[nName+1] = '\0';
|
|
+ if (!strcmp(Name, "/"))
|
|
+ depName = xstrdup(Name);
|
|
+ else {
|
|
+ depName = xmalloc(nName + 1 + 1);
|
|
+ (void) stpcpy(depName, Name);
|
|
+ /* XXX re-add the pesky trailing '/' to dirnames. */
|
|
+ depName[nName] = (tagno == RPMTAG_DIRNAMES ? '/' : '\0');
|
|
+ depName[nName+1] = '\0';
|
|
+ }
|
|
|
|
if (depName[0] == '/' && psm->Tmires != NULL) {
|
|
miRE mire;
|