char* LoadFile(const char* filename){
char* content = NULL;
unsigned int size = 0;
if (access(filename, F_OK) == 0){
FILE *fp = fopen(filename, "rb");
if(fp != NULL){
fseek(fp, 0L, SEEK_END);
size = ftell(fp);
fseek(fp, 0L, SEEK_SET);
content = (char*)malloc(size+1);
if(content!= NULL){
fread(content, 1, size, fp);
content[size]=0;
}
fclose(fp);
}
}
return content;
}