PORT_Free(filedata.data);
SECU_ReadDERFromFile(SECItem *der, PRFileDesc *inFile, PRBool ascii){    SECStatus rv;    char *asc, *body, *trailer;    if (ascii) {	/* First convert ascii to binary */	SECItem filedata;	/* Read in ascii data */	rv = SECU_FileToItem(&filedata, inFile);	asc = (char *)filedata.data;	if (!asc) {	    fprintf(stderr, "unable to read data from input file\n");	    return SECFailure;	}	/* check for headers and trailers and remove them */	if ((body = strstr(asc, "-----BEGIN")) != NULL) {	    body = PORT_Strchr(body, '\n') + 1;	    trailer = strstr(body, "-----END");	    if (trailer != NULL) {		*trailer = '\0';	    } else {		fprintf(stderr, "input has header but no trailer\n");		return SECFailure;	    }	} else {	    body = asc;	}     	/* Convert to binary */	rv = ATOB_ConvertAsciiToItem(der, body);	if (rv) {	    fprintf(stderr, "error converting ascii to binary (%s)\n",		    SECU_Strerror(PORT_GetError()));	    return SECFailure;	}	PORT_Free(asc);    } else {	/* Read in binary der */	rv = SECU_FileToItem(der, inFile);	if (rv) {	    fprintf(stderr, "error converting der (%s)\n", 		    SECU_Strerror(PORT_GetError()));	    return SECFailure;	}    }    return SECSuccess;}