Revision: 41210
          http://brlcad.svn.sourceforge.net/brlcad/?rev=41210&view=rev
Author:   brlcad
Date:     2010-11-02 10:20:43 +0000 (Tue, 02 Nov 2010)

Log Message:
-----------
this is the cause of the spurious bu_bomb() /dev/tty print messages infesting 
my conversion script.  need to catch exceptions thrown by nmg_bot().

Modified Paths:
--------------
    brlcad/trunk/src/libged/facetize.c

Modified: brlcad/trunk/src/libged/facetize.c
===================================================================
--- brlcad/trunk/src/libged/facetize.c  2010-11-02 10:11:32 UTC (rev 41209)
+++ brlcad/trunk/src/libged/facetize.c  2010-11-02 10:20:43 UTC (rev 41210)
@@ -250,9 +250,23 @@
 
        bu_vls_printf(&gedp->ged_result_str, "facetize:  converting to BOT 
format\n");
 
+       /* WTF, FIXME: this is only dumping the first shell of the first region 
*/
        r = BU_LIST_FIRST(nmgregion, &nmg_model->r_hd);
        s = BU_LIST_FIRST(shell, &r->s_hd);
-       bot = (struct rt_bot_internal *)nmg_bot(s, &gedp->ged_wdbp->wdb_tol);
+       if (BU_SETJUMP) {
+           BU_UNSETJUMP;
+           bu_vls_printf(&gedp->ged_result_str, "WARNING: conversion to BOT 
failed!\n");
+           if (facetize_tree)
+               db_free_tree(facetize_tree, &rt_uniresource);
+           facetize_tree = (union tree *)NULL;
+           nmg_km(nmg_model);
+           nmg_model = (struct model *)NULL;
+           return GED_ERROR;
+           
+       } else {
+           bot = (struct rt_bot_internal *)nmg_bot(s, 
&gedp->ged_wdbp->wdb_tol);
+       } BU_UNSETJUMP;
+
        nmg_km(nmg_model);
        nmg_model = (struct model *)NULL;
 


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to