Browse code

cosmetics

git-svn-id: file:///var/lib/svn/clamav-devel/trunk/clamav-devel@1434 77e5149b-7576-45b1-b177-96237e5ba77b

Tomasz Kojm authored on 2005/03/26 06:26:09
Showing 2 changed files
... ...
@@ -325,7 +325,7 @@ static int MainHeadSize;
325 325
 
326 326
 static long CurBlockPos,NextBlockPos;
327 327
 
328
-static unsigned long CurUnpRead, CurUnpWrite;
328
+static unsigned long CurUnpRead;
329 329
 static long UnpPackedSize;
330 330
 static long DestUnpSize;
331 331
 
... ...
@@ -535,7 +535,7 @@ int urarlib_list(int desc, ArchiveList_struct *list)
535 535
 #endif
536 536
   (*(DWORD*)list) = (DWORD)NULL;            /* init file list               */
537 537
   /* do while file is not extracted and there's no error                    */
538
-  while (TRUE)
538
+  for(;;)
539 539
   {
540 540
     int ReadBlockResult;
541 541
     if ((ReadBlockResult = ReadBlock(FILE_HEAD | READSUBBLOCK)) <= 0) /* read name of the next  */
... ...
@@ -1037,7 +1037,7 @@ BOOL ExtrFile(int desc)
1037 1037
         break;                              /* error, can't extract file!   */
1038 1038
       }
1039 1039
 
1040
-      CurUnpRead=CurUnpWrite=0;
1040
+      CurUnpRead=0;
1041 1041
       if ((*Password!=0) && (NewLhd.Flags & LHD_PASSWORD))
1042 1042
         Encryption=NewLhd.UnpVer;
1043 1043
       else
... ...
@@ -73,7 +73,7 @@
73 73
 int pefromupx (char *src, char *dst, int *dsize, uint32_t ep, uint32_t upx0, uint32_t upx1, uint32_t magic)
74 74
 {
75 75
   char *imports, *sections, *pehdr, *newbuf;
76
-  int sectcnt, upd=1, realstuffsz, align;
76
+  int sectcnt, upd=1, realstuffsz;
77 77
   int foffset=0xd0+0xf8;
78 78
 
79 79
   imports = dst + cli_readint32(src + ep - upx1 + magic);
... ...
@@ -108,7 +108,7 @@ int pefromupx (char *src, char *dst, int *dsize, uint32_t ep, uint32_t upx0, uin
108 108
     return 0;
109 109
   }
110 110
   
111
-  if (! (align = cli_readint32(pehdr+0x38))) {
111
+  if (! cli_readint32(pehdr+0x38)) {
112 112
     cli_dbgmsg("UPX: Cant align to a NULL bound - giving up rebuild\n");
113 113
     return 0;
114 114
   }
... ...
@@ -397,7 +397,7 @@ int upx_inflate2e(char *src, int ssize, char *dst, int *dsize, uint32_t upx0, ui
397 397
   int32_t backbytes, unp_offset = -1, myebx = 0;
398 398
   int scur=0, dcur=0, i, backsize, oob;
399 399
 
400
-  while (1) {
400
+  for(;;) {
401 401
     while ( (oob = doubleebx(src, &myebx, &scur, ssize)) ) {
402 402
       if (oob == -1)
403 403
         return -1;
... ...
@@ -408,7 +408,7 @@ int upx_inflate2e(char *src, int ssize, char *dst, int *dsize, uint32_t upx0, ui
408 408
 
409 409
     backbytes = 1;
410 410
 
411
-    while (1) {
411
+    for(;;) {
412 412
       if ( (oob = doubleebx(src, &myebx, &scur, ssize)) == -1 )
413 413
         return -1;
414 414
       backbytes = backbytes*2+oob;