Hi Jason, I've just done a review of your changes and feel hat the second set of checks for FILE_NOT_FOUND doesn't require the check against the server address as a previous if (containsServerAddress()) code block will mean that the value in the later code will always be false.
Assuming my interpretation is correct, I've only merge your first block of changes and ignored the second block of changes, these changes are now checked in svn/trunk. Could you review the code to see if I've done the right thing. Cheers, Robert. On Thu, Jan 15, 2009 at 4:47 PM, Jason Beverage <[email protected]> wrote: > Hi Robert, > > I realized today that there is an issue with the Registry changes I > submitted to allow plugins to have the first go at URLs. > > The code works fine as is if the format plugin is not already loaded in > memory. > > If a plugin is already in memory, say the PNG plugin for example, then a > call to readImageFile("http://server.com/image.png") will return > FILE_NOT_FOUND because osgDB::findDataFile will not be able to locate the > file. So the Registry::read method is returning before the CURL plugin is > given a chance to download the file. > > I've made a few changes to the Registry to not return FILE_NOT_FOUND if the > filename contains a URL that fix the issue. > > Thanks! > > Jason > > On Mon, Jan 5, 2009 at 1:17 PM, Jason Beverage <[email protected]> > wrote: >> >> Thanks Robert! Hope you had a good holiday:) >> >> On Mon, Jan 5, 2009 at 12:30 PM, Robert Osfield <[email protected]> >> wrote: >>> >>> Hi Jason, >>> >>> I've just reviewed, merged and tested your changes and everything >>> looks solid, even when loading http paged databases that have a local >>> cache so everything looks solid w.r.t original functional :-) >>> >>> Changes now checked into svn. >>> >>> Robert. >>> >>> On Thu, Dec 18, 2008 at 2:27 PM, Jason Beverage <[email protected]> >>> wrote: >>> > Hi Robert, >>> > >>> > I thought about the issue I was having with the CURL plugin >>> > automatically >>> > trying to download all filenames with URL's rather than passing the >>> > full URL >>> > to the plugin. It turns out the solution was pretty simple. >>> > >>> > I've made a small change to Registry.cpp that puts the CURL logic AFTER >>> > the >>> > URL has been passed to the plugin rather than assuming all URL's need >>> > to be >>> > downloaded by the CURL plugin. This way, plugins can have first crack >>> > at >>> > the URL's, and if they don't handle it the previous CURL behavior kicks >>> > in. >>> > >>> > Thanks! >>> > >>> > Jason >>> > >>> > _______________________________________________ >>> > osg-submissions mailing list >>> > [email protected] >>> > >>> > http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org >>> > >>> > >>> _______________________________________________ >>> osg-submissions mailing list >>> [email protected] >>> >>> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org >> > > > _______________________________________________ > osg-submissions mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org > > _______________________________________________ osg-submissions mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
