From: Panu Matilainen Date: Mon, 29 Mar 2010 07:59:58 +0000 (+0300) Subject: Unbreak cpio archive path generation X-Git-Tag: rpm-4.9.0-beta1~751 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=343d3a2cf7a3ad70ab0e056a156b03c4b1212c0b;p=platform%2Fupstream%2Frpm.git Unbreak cpio archive path generation - fixes regression from commit 45e2d4e1d0260a9c07eb1daf0c68b82f602ad16f - striplen was never set on build at all, and the psm part was unused too - either unused since forever or possibly related to repackaging --- diff --git a/lib/fsm.c b/lib/fsm.c index 3b9a4c4..01d5f1e 100644 --- a/lib/fsm.c +++ b/lib/fsm.c @@ -874,8 +874,7 @@ static int writeFile(FSM_t fsm, int writeData) fsm->dirName, fsm->baseName, NULL); } else if (fsm->mapFlags & CPIO_MAP_PATH) { rpmfi fi = fsmGetFi(fsm); - int striplen = 1; /* strip leading / from archive paths */ - fsm->path = xstrdup((fi->apath ? fi->apath[fsm->ix] + striplen : + fsm->path = xstrdup((fi->apath ? fi->apath[fsm->ix] : rpmfiBNIndex(fi, fsm->ix))); }