libobs: Ensure module exists before getting locale string

This commit is contained in:
Penwywern
2026-08-20 18:25:04 -04:00
committed by Ryan Foster
parent b790a32b2e
commit 4cc9c4466c
+2 -1
View File
@@ -63,7 +63,8 @@ static int load_module_exports(struct obs_module *mod, const char *path)
bool obs_module_get_locale_string(const obs_module_t *mod, const char *lookup_string, const char **translated_string)
{
if (mod->get_string) {
assert(mod);
if (mod && mod->get_string) {
return mod->get_string(lookup_string, translated_string);
}