if (CacheLoadConfig (module, file) != VLC_SUCCESS)
goto error;
- LOAD_STRING(module->psz_filename);
LOAD_STRING(module->domain);
if (module->domain != NULL)
vlc_bindtextdomain (module->domain);
if (CacheSaveConfig (file, module))
goto error;
- SAVE_STRING(module->psz_filename);
SAVE_STRING(module->domain);
i_submodule = module->submodule_count;
{
while (count > 0)
{
- if (!strcmp (cache->path, path)
+ if (cache->path != NULL
+ && !strcmp (cache->path, path)
&& cache->mtime == st->st_mtime
&& cache->size == st->st_size)
{
module_t *module = cache->p_module;
- cache->p_module = NULL; /* Return NULL next time */
+ cache->p_module = NULL;
+
+ module->psz_filename = cache->path;
+ cache->path = NULL;
return module;
}
cache++;