Pārlūkot izejas kodu

dpkg: Reduce scope of status variable to avoid shadowing another one

Guillem Jover 16 gadi atpakaļ
vecāks
revīzija
c58fa9fa33
1 mainītis faili ar 3 papildinājumiem un 1 dzēšanām
  1. 3 1
      src/processarc.c

+ 3 - 1
src/processarc.c

@@ -95,7 +95,7 @@ void process_archive(const char *filename) {
   static struct varbuf infofnvb, fnvb, depprobwhy;
   static struct varbuf infofnvb, fnvb, depprobwhy;
   static struct tarcontext tc;
   static struct tarcontext tc;
   
   
-  int c1, r, admindirlen, i, infodirlen, infodirbaseused, status;
+  int c1, r, admindirlen, i, infodirlen, infodirbaseused;
   struct pkgiterator *it;
   struct pkgiterator *it;
   struct pkginfo *pkg, *otherpkg, *divpkg;
   struct pkginfo *pkg, *otherpkg, *divpkg;
   char *cidir, *cidirrest, *p;
   char *cidir, *cidirrest, *p;
@@ -125,6 +125,8 @@ void process_archive(const char *filename) {
   if (stat(filename,&stab)) ohshite(_("cannot access archive"));
   if (stat(filename,&stab)) ohshite(_("cannot access archive"));
 
 
   if (!f_noact) {
   if (!f_noact) {
+    int status;
+
     /* We can't `tentatively-reassemble' packages. */
     /* We can't `tentatively-reassemble' packages. */
     if (!reasmbuf) {
     if (!reasmbuf) {
       reasmbuf= m_malloc(admindirlen+sizeof(REASSEMBLETMP)+5);
       reasmbuf= m_malloc(admindirlen+sizeof(REASSEMBLETMP)+5);