j = GET_32BIT(buf+i);
i += 4;
if (len-i < j) goto end;
- comment = malloc(j+1);
+ comment = smalloc(j+1);
if (comment) {
memcpy(comment, buf+i, j);
comment[j] = '\0';
!strcmp(buf, rsa_signature)) {
return loadrsakey_main(fp, NULL, NULL, comment, NULL);
}
+ fclose(fp);
return 0; /* wasn't the right kind of file */
}
unsigned char buf[16384];
unsigned char keybuf[16];
struct MD5Context md5c;
- char *p, *estart;
+ unsigned char *p, *estart;
FILE *fp;
/*