Bladeren bron

[base16] Fix comparison of signed and unsigned integers

gcc 4.7.1 fails to report this erroneous comparison unless assertions
are enabled.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 11 jaren geleden
bovenliggende
commit
4f078801e9
1 gewijzigde bestanden met toevoegingen van 1 en 1 verwijderingen
  1. 1
    1
      src/core/base16.c

+ 1
- 1
src/core/base16.c Bestand weergeven

@@ -129,7 +129,7 @@ int base16_decode ( const char *encoded, uint8_t *raw ) {
129 129
 
130 130
 	DBG ( "Base16-decoded \"%s\" to:\n", encoded );
131 131
 	DBG_HDA ( 0, raw, len );
132
-	assert ( len <= base16_decoded_max_len ( encoded ) );
132
+	assert ( len <= ( int ) base16_decoded_max_len ( encoded ) );
133 133
 
134 134
 	return len;
135 135
 }

Laden…
Annuleren
Opslaan