[trunk] Remove mem leak and warning reported by clang

This commit is contained in:
Mathieu Malaterre 2014-03-07 11:17:51 +00:00
parent fc9248ea2b
commit 22d11a9ccb
1 changed files with 1 additions and 3 deletions

View File

@ -408,9 +408,7 @@ static int get_file_format(char *filename) {
} }
static char * get_file_name(char *name){ static char * get_file_name(char *name){
char *fname; char *fname = strtok(name,".");
fname= (char*)malloc(OPJ_PATH_LEN*sizeof(char));
fname= strtok(name,".");
return fname; return fname;
} }