On 11/01/2011 10:06 AM, Steve Schwartz wrote: > Dear All, > > Is there a good reason why plexit must force a program abort even if the > programmer has written their own exit_handler? For simple user-written > code I guess this isn't too much of a problem, but for anything that is > distributed or given to a third party, having an application crash is > very unkind. In addition to the annoyance of the crash, the lost work > (which en exit_handler might/might not be able to minimise), and the > inability or difficulty in fixing or avoiding the crash next time, such > a crash reflects badly on the author of the application. > > I would have thought that plexit could/should: > > Check if there is an exit_handler > If so, pass control to it and on return execute a simple return > If not, then I guess crashing immediately might be best > > This gives the programmer the opportunity and responsibility to deal > with the error if they can/wish.
The trick is to write your exit handler so that it does not return control to PLplot. -Hazen ------------------------------------------------------------------------------ RSA® Conference 2012 Save $700 by Nov 18 Register now! http://p.sf.net/sfu/rsa-sfdev2dev1 _______________________________________________ Plplot-devel mailing list Plplot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/plplot-devel