From 050eba408d44d8c1a53e5d6ec2a178fc38112e62 Mon Sep 17 00:00:00 2001 From: Chris Young Date: Mon, 14 Mar 2011 18:32:05 +0000 Subject: [PATCH] Avoid crash when no theme is present svn path=/trunk/netsurf/; revision=12047 --- amiga/theme.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/amiga/theme.c b/amiga/theme.c index a6fe97d5a..4f442f397 100644 --- a/amiga/theme.c +++ b/amiga/theme.c @@ -115,7 +115,12 @@ void ami_theme_init(void) UnLock(lock); } - messages_load(themefile); + lock = Lock(themefile,ACCESS_READ); + if(lock) + { + UnLock(lock); + messages_load(themefile); + } } void ami_theme_throbber_setup(void)