read_comprssed_file - cleanups

This commit is contained in:
twinaphex 2016-01-24 04:27:20 +01:00
parent 6a7674dca1
commit 20cf52a316

View File

@ -479,18 +479,16 @@ int read_compressed_file(const char * path, void **buf,
const char* file_ext = NULL;
struct string_list *str_list = string_split(path, "#");
if (optional_filename)
/* Safety check.
* If optional_filename and optional_filename
* exists, we simply return 0,
* hoping that optional_filename is the
* same as requested.
*/
if (optional_filename && path_file_exists(optional_filename))
{
/* Safety check. * If optional_filename and optional_filename
* exists, we simply return 0,
* hoping that optional_filename is the
* same as requested.
*/
if(path_file_exists(optional_filename))
{
*length = 0;
return 1;
}
*length = 0;
return 1;
}
/* We assure that there is something after the '#' symbol.