fix problem with unsigned int; pointe out by Douglas E. Engert <deengert@anl.gov>

git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2315 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
nils 2005-04-19 18:38:26 +00:00
parent 20059c984f
commit 9ad11a6b28

View File

@ -337,7 +337,7 @@ static int sc_pkcs15emu_gemsafe_init(sc_pkcs15_card_t *p15card)
cert_obj.flags = certs[i].obj_flags;
while (idx1 < file->size - 16) { /* actually 13 for all these tests */
if (idx1 > idx2 - 16) { /* need more data in buff */
if (idx1 + 16 > idx2 ) { /* need more data in buff */
idxlen = 248; /* read in next 248 bytes */
if (idxlen > file->size - idx2)
idxlen = file->size - idx2;