xmlsecurityengine/xmlseccrypto/src/xmlsecc_bio.cpp
changeset 1 29dae20d06bf
parent 0 e35f40988205
child 16 d10d750052f0
equal deleted inserted replaced
0:e35f40988205 1:29dae20d06bf
    86 	        }
    86 	        }
    87 	    return(NULL);
    87 	    return(NULL);
    88 	    }
    88 	    }
    89 	fseek(fp, 0, SEEK_END);
    89 	fseek(fp, 0, SEEK_END);
    90 	fileLen = ftell(fp);
    90 	fileLen = ftell(fp);
    91     fseek ( fp , 0L , SEEK_SET );
    91 	if(fileLen < 0)
       
    92 		{
       
    93 			xmlSecSetErrorFlag( KErrGeneral );
       
    94 			return(NULL);
       
    95 		}
       
    96 	fseek ( fp , 0L , SEEK_SET );
    92 	
    97 	
    93 	buf = (char *)malloc(sizeof(char)*(fileLen+1));
    98 	buf = (char *)malloc(sizeof(char)*(fileLen+1));
    94     if(!buf) {	   
    99     if(!buf) {	   
    95 		xmlSecSetErrorFlag( KErrNoMemory );
   100 		xmlSecSetErrorFlag( KErrNoMemory );
    96 	    return(NULL);
   101 	    return(NULL);