Nice catch Cliff!  I’d forgotten about db_create() doing some work for us.  Of 
course, it shouldn’t matter if we rt_dirbuild() multiple times without it 
causing problems, but that’s still a TODO to fix that.

Cheers!
Sean



> On Dec 3, 2018, at 8:54 AM, starseeker--- via brlcad-commits 
> <brlcad-comm...@lists.sourceforge.net> wrote:
> 
> Revision: 72098
>          http://sourceforge.net/p/brlcad/code/72098
> Author:   starseeker
> Date:     2018-12-03 13:54:51 +0000 (Mon, 03 Dec 2018)
> Log Message:
> -----------
> Cherrypick r72097 into Release - avoid repeated db_dirbuild call when using 
> db_create to make a new file - db_create already calls db_dirbuild.
> 
> Modified Paths:
> --------------
>    brlcad/branches/RELEASE/src/librt/cache.c
> 
> Property Changed:
> ----------------
>    brlcad/branches/RELEASE/
>    brlcad/branches/RELEASE/CHANGES
>    brlcad/branches/RELEASE/NEWS
>    brlcad/branches/RELEASE/bench/
>    brlcad/branches/RELEASE/db/
>    brlcad/branches/RELEASE/doc/
>    brlcad/branches/RELEASE/doc/STRATEGY
>    brlcad/branches/RELEASE/doc/docbook/articles/
>    brlcad/branches/RELEASE/doc/docbook/books/
>    brlcad/branches/RELEASE/doc/docbook/lessons/
>    brlcad/branches/RELEASE/include/
>    brlcad/branches/RELEASE/regress/
>    brlcad/branches/RELEASE/regress/repository.sh
>    brlcad/branches/RELEASE/src/libged/polyclip.cpp
>    brlcad/branches/RELEASE/src/other/
> 
> Index: brlcad/branches/RELEASE
> ===================================================================
> --- brlcad/branches/RELEASE   2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE   2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl:65867-66137
> /brlcad/branches/osg:62110-62113
> /brlcad/branches/prep-cache:68236-68933
> -/brlcad/trunk:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72083,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72083,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/CHANGES
> ===================================================================
> --- brlcad/branches/RELEASE/CHANGES   2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/CHANGES   2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/CHANGES
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/CHANGES:65867-66137
> /brlcad/branches/osg/CHANGES:62110-62113
> /brlcad/branches/prep-cache/CHANGES:68236-68933
> -/brlcad/trunk/CHANGES:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/CHANGES:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/NEWS
> ===================================================================
> --- brlcad/branches/RELEASE/NEWS      2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/NEWS      2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/NEWS
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -7,4 +7,4 ##
> /brlcad/branches/osg/NEWS:62110-62113
> /brlcad/branches/prep-cache/NEWS:68236-68933
> /brlcad/trunk:68170-68252
> -/brlcad/trunk/NEWS:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/NEWS:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/bench
> ===================================================================
> --- brlcad/branches/RELEASE/bench     2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/bench     2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/bench
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/bench:65867-66137
> /brlcad/branches/osg/bench:62110-62113
> /brlcad/branches/prep-cache/bench:68236-68933
> -/brlcad/trunk/bench:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/bench:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/db
> ===================================================================
> --- brlcad/branches/RELEASE/db        2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/db        2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/db
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/db:65867-66137
> /brlcad/branches/osg/db:62110-62113
> /brlcad/branches/prep-cache/db:68236-68933
> -/brlcad/trunk/db:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/db:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/doc
> ===================================================================
> --- brlcad/branches/RELEASE/doc       2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/doc       2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/doc
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/doc:65867-66137
> /brlcad/branches/osg/doc:62110-62113
> /brlcad/branches/prep-cache/doc:68236-68933
> -/brlcad/trunk/doc:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/doc:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/doc/STRATEGY
> ===================================================================
> --- brlcad/branches/RELEASE/doc/STRATEGY      2018-12-01 21:30:51 UTC (rev 
> 72097)
> +++ brlcad/branches/RELEASE/doc/STRATEGY      2018-12-03 13:54:51 UTC (rev 
> 72098)
> 
> Property changes on: brlcad/branches/RELEASE/doc/STRATEGY
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/doc/STRATEGY:65867-66137
> /brlcad/branches/osg/doc/STRATEGY:62110-62113
> /brlcad/branches/prep-cache/doc/STRATEGY:68236-68933
> -/brlcad/trunk/doc/STRATEGY:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/doc/STRATEGY:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/doc/docbook/articles
> ===================================================================
> --- brlcad/branches/RELEASE/doc/docbook/articles      2018-12-01 21:30:51 UTC 
> (rev 72097)
> +++ brlcad/branches/RELEASE/doc/docbook/articles      2018-12-03 13:54:51 UTC 
> (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/doc/docbook/articles
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/doc/docbook/articles:65867-66137
> /brlcad/branches/osg/doc/docbook/articles:62110-62113
> /brlcad/branches/prep-cache/doc/docbook/articles:68236-68933
> -/brlcad/trunk/doc/docbook/articles:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/doc/docbook/articles:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/doc/docbook/books
> ===================================================================
> --- brlcad/branches/RELEASE/doc/docbook/books 2018-12-01 21:30:51 UTC (rev 
> 72097)
> +++ brlcad/branches/RELEASE/doc/docbook/books 2018-12-03 13:54:51 UTC (rev 
> 72098)
> 
> Property changes on: brlcad/branches/RELEASE/doc/docbook/books
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/doc/docbook/books:65867-66137
> /brlcad/branches/osg/doc/docbook/books:62110-62113
> /brlcad/branches/prep-cache/doc/docbook/books:68236-68933
> -/brlcad/trunk/doc/docbook/books:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/doc/docbook/books:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/doc/docbook/lessons
> ===================================================================
> --- brlcad/branches/RELEASE/doc/docbook/lessons       2018-12-01 21:30:51 UTC 
> (rev 72097)
> +++ brlcad/branches/RELEASE/doc/docbook/lessons       2018-12-03 13:54:51 UTC 
> (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/doc/docbook/lessons
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/doc/docbook/lessons:65867-66137
> /brlcad/branches/osg/doc/docbook/lessons:62110-62113
> /brlcad/branches/prep-cache/doc/docbook/lessons:68236-68933
> -/brlcad/trunk/doc/docbook/lessons:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/doc/docbook/lessons:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/include
> ===================================================================
> --- brlcad/branches/RELEASE/include   2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/include   2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/include
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/include:65867-66137
> /brlcad/branches/osg/include:62110-62113
> /brlcad/branches/prep-cache/include:68236-68933
> -/brlcad/trunk/include:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/include:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/regress
> ===================================================================
> --- brlcad/branches/RELEASE/regress   2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/regress   2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/regress
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/regress:65867-66137
> /brlcad/branches/osg/regress:62110-62113
> /brlcad/branches/prep-cache/regress:68236-68933
> -/brlcad/trunk/regress:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/regress:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/regress/repository.sh
> ===================================================================
> --- brlcad/branches/RELEASE/regress/repository.sh     2018-12-01 21:30:51 UTC 
> (rev 72097)
> +++ brlcad/branches/RELEASE/regress/repository.sh     2018-12-03 13:54:51 UTC 
> (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/regress/repository.sh
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/regress/repository.sh:65867-66137
> /brlcad/branches/osg/regress/repository.sh:62110-62113
> /brlcad/branches/prep-cache/regress/repository.sh:68236-68933
> -/brlcad/trunk/regress/repository.sh:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/regress/repository.sh:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Index: brlcad/branches/RELEASE/src/libged/polyclip.cpp
> ===================================================================
> --- brlcad/branches/RELEASE/src/libged/polyclip.cpp   2018-12-01 21:30:51 UTC 
> (rev 72097)
> +++ brlcad/branches/RELEASE/src/libged/polyclip.cpp   2018-12-03 13:54:51 UTC 
> (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/src/libged/polyclip.cpp
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -4,4 +4,4 ##
> /brlcad/branches/gct/src/libged/polyclip.cpp:62423-62425
> /brlcad/branches/osg/src/libged/polyclip.cpp:62110-62113
> /brlcad/branches/prep-cache/src/libged/polyclip.cpp:68236-68933
> -/brlcad/trunk/src/libged/polyclip.cpp:50761-68099,68132-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/src/libged/polyclip.cpp:50761-68099,68132-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> Modified: brlcad/branches/RELEASE/src/librt/cache.c
> ===================================================================
> --- brlcad/branches/RELEASE/src/librt/cache.c 2018-12-01 21:30:51 UTC (rev 
> 72097)
> +++ brlcad/branches/RELEASE/src/librt/cache.c 2018-12-03 13:54:51 UTC (rev 
> 72098)
> @@ -372,15 +372,15 @@
>       dbip = db_create(db, 5);
>     } else {
>       dbip = db_open(db, DB_OPEN_READWRITE);
> +     if (dbip && db_dirbuild(dbip)) {
> +         db_close(dbip);
> +         return NULL;
> +     }
>     }
> +
>     if (!dbip)
>       return NULL;
> 
> -    if (db_dirbuild(dbip)) {
> -     db_close(dbip);
> -     return NULL;
> -    }
> -
>     bu_hash_set(cache->dbip_hash, (const uint8_t *)name, strlen(name), dbip);
>     return dbip;
> }
> 
> Index: brlcad/branches/RELEASE/src/other
> ===================================================================
> --- brlcad/branches/RELEASE/src/other 2018-12-01 21:30:51 UTC (rev 72097)
> +++ brlcad/branches/RELEASE/src/other 2018-12-03 13:54:51 UTC (rev 72098)
> 
> Property changes on: brlcad/branches/RELEASE/src/other
> ___________________________________________________________________
> Modified: svn:mergeinfo
> ## -6,4 +6,4 ##
> /brlcad/branches/opencl/src/other:65867-66137
> /brlcad/branches/osg/src/other:62110-62113
> /brlcad/branches/prep-cache/src/other:68236-68933
> -/brlcad/trunk/src/other:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092
> \ No newline at end of property
> +/brlcad/trunk/src/other:36844-37285,37571-38764,38777-38845,41559-43155,43159-43908,44241-44324,44326-44385,44710-45373,45377,45379-47342,47370-68122,68125-71929,71943-71945,71952-71953,71990-71997,72004,72073,72087,72089,72091-72092,72097
> \ No newline at end of property
> This was sent by the SourceForge.net collaborative development platform, the 
> world's largest Open Source development site.
> 
> 
> 
> _______________________________________________
> BRL-CAD Source Commits mailing list
> brlcad-comm...@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/brlcad-commits



_______________________________________________
BRL-CAD Developer mailing list
brlcad-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/brlcad-devel

Reply via email to