Skip to content
This repository
Browse code

Merge pull request #15 from renegadezombies/patch-1

Update img3unpack/img3.c
  • Loading branch information...
commit 4f5978c271d9bf913c94870380e305992f23bfb8 2 parents 2bcd24c + c032011
planetbeing authored February 07, 2013

Showing 1 changed file with 10 additions and 10 deletions. Show diff stats Hide diff stats

  1. 20  img3unpack/img3.c
20  img3unpack/img3.c
@@ -25,24 +25,24 @@ void dumpImg3Header(const Img3* header)
25 25
 	printf("Header size: %d\n", sizeof(*header));
26 26
 
27 27
 	printf("Magic:       0x%x (%s)\n", header->magic, str_magic(header->magic));
28  
-	printf("Length:      %ld\n", header->dataLenPad);
29  
-	printf("Unknown:     %ld\n", header->u1);
30  
-	printf("Cert Offset: %ld\n", header->certOffset);
  28
+	printf("Length:      %u\n", header->dataLenPad);
  29
+	printf("Unknown:     %u\n", header->u1);
  30
+	printf("Cert Offset: %u\n", header->certOffset);
31 31
 	printf("Name:        0x%x (%s)\n", header->name, str_magic(header->name));
32 32
 	printf("Type:        0x%x (%s)\n", header->type, str_magic(header->type));
33  
-	printf("nameOffset:  %ld\n", header->nameOffset);
34  
-	printf("dataLen:     %ld\n", header->dataLen);
  33
+	printf("nameOffset:  %u\n", header->nameOffset);
  34
+	printf("dataLen:     %u\n", header->dataLen);
35 35
 }
36 36
 void dumpImg3Footer(const Img3_footer2* footer)
37 37
 {
38 38
 	printf("=======================================\n");
39 39
 	printf("Footer size: %d\n", sizeof(*footer));
40 40
 
41  
-	printf("Block Size: %ld bytes\n", footer->blockSize);
42  
-	printf("Signature:  %ld bytes\n", footer->sigLen);
  41
+	printf("Block Size: %u bytes\n", footer->blockSize);
  42
+	printf("Signature:  %u bytes\n", footer->sigLen);
43 43
 	printf("Cert Head:  0x%x (%s)\n", footer->cert_magic, str_magic(footer->cert_magic));
44  
-	printf("Cert Size:  %ld\n", footer->cert_size);
45  
-	printf("Certficate: %ld bytes\n", sizeof(footer->cert));
  44
+	printf("Cert Size:  %u\n", footer->cert_size);
  45
+	printf("Certficate: %u bytes\n", sizeof(footer->cert));
46 46
 
47 47
 }
48 48
 int main(int argc, char *argv[]) {
@@ -117,7 +117,7 @@ int main(int argc, char *argv[]) {
117 117
 		offSet = sizeof(*dF);
118 118
     while(offSet < pHeaderImg3->dataLenPad) {
119 119
     	printf("Flag:        0x%x (%s)\n", dF->name, str_magic(dF->name));
120  
-			printf("Offset:      %ld\n", offSet);
  120
+			printf("Offset:      %d\n", offSet);
121 121
       if(dF->name == END_FLAG_HSHS) {
122 122
 				offSet += - 16;
123 123
 				memcpy(pFooterImg3_2, (fBuf + sizeof(Img3) + pHeaderImg3->nameOffset) - 12 + offSet, sizeof(*pFooterImg3_2));

0 notes on commit 4f5978c

Please sign in to comment.
Something went wrong with that request. Please try again.