Bob, the problem is that db_open() use of mapped files can (and did) fail. If mapping the file fails, then the second db_open() returns a fresh dbip with no directory built (and rtedge fails to render). What about just making db_dirbuild() just not be so noisy if the directory is already built, have it not blindly build the directory on top of an existing one?
On May 1, 2012, at 12:02 PM, bob1...@users.sourceforge.net wrote: > Revision: 50376 > http://brlcad.svn.sourceforge.net/brlcad/?rev=50376&view=rev > Author: bob1961 > Date: 2012-05-01 16:02:11 +0000 (Tue, 01 May 2012) > Log Message: > ----------- > Don't need the call to db_dirbuild() in viewedge.c/view_init() because the > db_open()'s here and in main.c are using mapped files. So the previous call > to rt_dirbuild() in main.c has already called db_dirbuild(). This avoids the > db_dircheck: Duplicate of ... error messages. > > Modified Paths: > -------------- > brlcad/trunk/src/rt/viewedge.c > > Modified: brlcad/trunk/src/rt/viewedge.c > =================================================================== > --- brlcad/trunk/src/rt/viewedge.c 2012-05-01 14:29:05 UTC (rev 50375) > +++ brlcad/trunk/src/rt/viewedge.c 2012-05-01 16:02:11 UTC (rev 50376) > @@ -455,8 +455,10 @@ > bu_exit(EXIT_FAILURE, "rtedge: could not open database.\n"); > RT_CK_DBI(dbip); > > +#if 0 > if (db_dirbuild(dbip) < 0) > bu_exit(EXIT_FAILURE, "rtedge: could not read database.\n"); > +#endif > > occlusion_rtip = rt_new_rti(dbip); /* clones dbip */ > > > This was sent by the SourceForge.net collaborative development platform, the > world's largest Open Source development site. > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > BRL-CAD Source Commits mailing list > brlcad-comm...@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/brlcad-commits ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ BRL-CAD Developer mailing list brlcad-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/brlcad-devel