[trunk] Remove mem leak and warning reported by clang
This commit is contained in:
parent
fc9248ea2b
commit
22d11a9ccb
|
@ -408,9 +408,7 @@ static int get_file_format(char *filename) {
|
|||
}
|
||||
|
||||
static char * get_file_name(char *name){
|
||||
char *fname;
|
||||
fname= (char*)malloc(OPJ_PATH_LEN*sizeof(char));
|
||||
fname= strtok(name,".");
|
||||
char *fname = strtok(name,".");
|
||||
return fname;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue