Show error instead of warning requester when essential library fails to open.

This commit is contained in:
Chris Young 2014-11-10 23:29:28 +00:00
parent 5776b39b8d
commit 91662977eb
2 changed files with 7 additions and 2 deletions

View File

@ -17,10 +17,12 @@
*/
#include "amiga/libs.h"
#include "amiga/misc.h"
#include "utils/utils.h"
#include "utils/log.h"
#include <proto/exec.h>
#include <proto/utility.h>
#define AMINS_LIB_OPEN(LIB, LIBVER, PREFIX, INTERFACE, INTVER, FAIL) \
LOG(("Opening %s v%d", LIB, LIBVER)); \
@ -32,8 +34,10 @@
} else { \
LOG(("Failed to open %s v%d", LIB, LIBVER)); \
if(FAIL == true) { \
warn_user("CompError", LIB); \
return false; \
STRPTR error = ASPrintf("Unable to open %s v%d", LIB, LIBVER); \
ami_misc_fatal_error(error); \
FreeVec(error); \
return false; \
} \
}

View File

@ -21,6 +21,7 @@
#include <exec/types.h>
extern struct gui_file_table *amiga_file_table;
struct Window;
char *translate_escape_chars(const char *s);
void ami_misc_fatal_error(const char *message);