Hi, I send these two patches updated to the newest dpkg (namely 1.13.22). Is there any chance that they'll be reviewed and probably committed by someone around there?
-- Egmont
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=281057 diff -Naur dpkg-1.13.22.orig/src/processarc.c dpkg-1.13.22/src/processarc.c --- dpkg-1.13.22.orig/src/processarc.c 2006-05-31 04:46:30.000000000 +0200 +++ dpkg-1.13.22/src/processarc.c 2006-06-29 17:22:39.000000000 +0200 @@ -646,15 +646,17 @@ "upgrade/downgrade", fnamevb.buf); for (cfile= newfileslist; cfile; cfile= cfile->next) { + struct stat st_tmp; if (!cfile->namenode->filestat) { - cfile->namenode->filestat= nfmalloc(sizeof(struct stat)); - if (lstat(cfile->namenode->name, cfile->namenode->filestat)) { + if (lstat(cfile->namenode->name, &st_tmp)) { if (!(errno == ENOENT || errno == ELOOP || errno == ENOTDIR)) ohshite(_("unable to stat other new file `%.250s'"), cfile->namenode->name); - memset(cfile->namenode->filestat, 0, - sizeof(cfile->namenode->filestat)); + cfile->namenode->filestat= 0; continue; + } else { + cfile->namenode->filestat= nfmalloc(sizeof(struct stat)); + memcpy(cfile->namenode->filestat, &st_tmp, sizeof(struct stat)); } } if (!cfile->namenode->filestat->st_mode) continue;
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=281057 diff -Naur dpkg-1.13.22.orig/src/processarc.c dpkg-1.13.22/src/processarc.c --- dpkg-1.13.22.orig/src/processarc.c 2006-06-29 17:24:20.000000000 +0200 +++ dpkg-1.13.22/src/processarc.c 2006-06-29 17:26:00.000000000 +0200 @@ -60,7 +60,7 @@ static char *cidirbuf=0, *reasmbuf=0; static struct fileinlist *newconffiles, *newfileslist; static enum pkgstatus oldversionstatus; - static struct varbuf infofnvb, fnvb, depprobwhy; + static struct varbuf infofnvb, fnvb, cfnvb, depprobwhy; static struct tarcontext tc; int c1, r, admindirlen, i, infodirlen, infodirbaseused, status; @@ -648,7 +648,12 @@ for (cfile= newfileslist; cfile; cfile= cfile->next) { struct stat st_tmp; if (!cfile->namenode->filestat) { - if (lstat(cfile->namenode->name, &st_tmp)) { + varbufreset(&cfnvb); + varbufaddstr(&cfnvb,instdir); + varbufaddc(&cfnvb,'/'); + varbufaddstr(&cfnvb,cfile->namenode->name); + varbufaddc(&cfnvb,0); + if (lstat(cfnvb.buf, &st_tmp)) { if (!(errno == ENOENT || errno == ELOOP || errno == ENOTDIR)) ohshite(_("unable to stat other new file `%.250s'"), cfile->namenode->name);