From 455e4d3d21dd62b33aafe2b052600346f4351cd4 Mon Sep 17 00:00:00 2001 From: Chris Young Date: Sun, 9 Nov 2014 00:25:29 +0000 Subject: Don't bug the user if a non-essential library can't be opened - just log it. Also log if the interface can't be obtained. If we've asked for the right library version, this should never fail. --- amiga/libs.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'amiga') diff --git a/amiga/libs.c b/amiga/libs.c index 23b29fc42..3cc84cb68 100644 --- a/amiga/libs.c +++ b/amiga/libs.c @@ -26,9 +26,15 @@ LOG(("Opening %s v%d", LIB, LIBVER)); \ if((PREFIX##Base = OpenLibrary(LIB, LIBVER))) { \ I##PREFIX = (struct PREFIX##IFace *)GetInterface(PREFIX##Base, INTERFACE, INTVER, NULL); \ + if(I##PREFIX == NULL) { \ + LOG(("Failed to get %s interface v%d of %s", INTERFACE, INTVER, LIB)); \ + } \ } else { \ - warn_user("CompError", LIB); \ - if(FAIL == true) return false; \ + LOG(("Failed to open %s v%d", LIB, LIBVER)); \ + if(FAIL == true) { \ + warn_user("CompError", LIB); \ + return false; \ + } \ } #define AMINS_LIB_CLOSE(PREFIX) \ -- cgit v1.2.3