Fix compilation with Visual Studio.

This commit is contained in:
Ghislain MARY 2014-04-22 16:07:00 +02:00
parent ceb8533cf9
commit 5f9dc1c5d8

View file

@ -57,11 +57,14 @@ static int linphone_remote_provisioning_load_file( LinphoneCore* lc, const char*
FILE* f = fopen(file_path, "r");
if( f ){
long fsize;
char* provisioning;
fseek(f, 0, SEEK_END);
long fsize = ftell(f);
fsize = ftell(f);
fseek(f, 0, SEEK_SET);
char* provisioning = ms_malloc(fsize + 1);
provisioning = ms_malloc(fsize + 1);
provisioning[fsize]='\0';
if (fread(provisioning, fsize, 1, f)==0){
ms_error("Could not read xml provisioning file from %s",file_path);