From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by yquem.inria.fr (Postfix) with ESMTP id 7AF5EBBAF for ; Sat, 13 Mar 2010 19:55:38 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AlgFABZum0tQRFuwWmdsb2JhbACacQsBFBUGOLk8hHsE X-IronPort-AV: E=Sophos;i="4.49,633,1262559600"; d="scan'208";a="58822558" Received: from furbychan.cocan.org ([80.68.91.176]) by mail4-smtp-sop.national.inria.fr with ESMTP; 13 Mar 2010 19:55:37 +0100 Received: from rich by furbychan.cocan.org with local (Exim 4.63) (envelope-from ) id 1NqWUr-00079A-3h; Sat, 13 Mar 2010 18:55:37 +0000 Date: Sat, 13 Mar 2010 18:55:37 +0000 To: Florent Monnier Cc: caml-list Subject: Re: [Caml-list] exception not registered.Abandon Message-ID: <20100313185537.GA27381@annexia.org> References: <201003131742.25933.monnier.florent@gmail.com> <20100313173822.GA24666@annexia.org> <201003131936.16333.monnier.florent@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201003131936.16333.monnier.florent@gmail.com> User-Agent: Mutt/1.5.13 (2006-08-11) From: Richard Jones X-Spam: no; 0.00; 0100,:01 compiler:01 stdlib:01 lib:01 windowing:01 exn:01 exn:01 fprintf:01 stderr:01 ocaml:01 bug:01 bindings:01 adrian:98 char:01 wrote:01 On Sat, Mar 13, 2010 at 07:36:16PM +0100, Florent Monnier wrote: > > > I have compiled a program using the native compiler, then when I run the > > > executable I get this error message: > > > > > > exception not registered.Abandon > > > > > > Searching Google I don't find anything about this error message. > > > How should I interpret it? > > > > Is the program linked to C code (apart from stdlib, I mean)? > > Yes it is. > It's linked with OpenGL (only the GL lib, no GLU or anything esle) and SDL > (through ocaml-sdl) > > It's a program that I try to switch the windowing part from Glut to SDL. > With Glut it works alright. > > Also I've just seen that running in the interpreted mode instead of native > code the program does run without any problem. > > Do these additional informations give you any clue? As Adrian said, it's from ocaml-SDL. It's from one of several functions which look like this: static void sdlloader_raise_exception (char *msg) { static value *loader_exn = NULL; if(! loader_exn){ loader_exn = caml_named_value("SDLloader_exception"); if(! loader_exn) { fprintf(stderr, "exception not registered."); abort(); } } raise_with_string(*loader_exn, msg); } Essentially you have to register OCaml exceptions before you can call them from C, so it sounds like you're not calling some sort of SDL "init" function (or calling it too late in your program). Or possibly there is a bug in the ocaml-SDL bindings. Rich. -- Richard Jones Red Hat