Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge changes from BRL-CAD Main Repo #18

Merged
merged 216 commits into from
Dec 16, 2021
Merged

Commits on Nov 17, 2021

  1. Check for null inputs

    starseeker committed Nov 17, 2021
    Configuration menu
    Copy the full SHA
    b002a79 View commit details
    Browse the repository at this point in the history

Commits on Nov 18, 2021

  1. Configuration menu
    Copy the full SHA
    22e9c1c View commit details
    Browse the repository at this point in the history
  2. Make a variety of adjustments to halftone - mostly initializing vars …

    …and memory, but also not proceeding if we can't read next successfully.
    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    8f15a9b View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    e4e0bbd View commit details
    Browse the repository at this point in the history
  4. Initialize variables.

    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    680f956 View commit details
    Browse the repository at this point in the history
  5. Initialize

    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    425b7e4 View commit details
    Browse the repository at this point in the history
  6. Initialize variables.

    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    ec861c2 View commit details
    Browse the repository at this point in the history
  7. Initialize variable.

    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    ce28586 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    77c8ecc View commit details
    Browse the repository at this point in the history
  9. As near as I can tell, this was added in commit svn::revision::9746 a…

    …s potentially needed by some ifdef 0 code, which was subsequently removed - unused.
    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    6febd62 View commit details
    Browse the repository at this point in the history
  10. ON_SimpleArray -> ON_ClassArray

    Sean spotted this, and it looks like it may have been a significant
    systematic mistake in my early NURBS brep coding.  ON_SimpleArray can't
    always be used - per opennurbs_array.h, ON_SimpleArray "should not be
    used for arrays of classes that require explicit construction,
    destruction, or copy operators."  That probably means we've got a lot of
    inappropriate uses of ON_SimpleArray at play.  I tended to try and treat
    pointers to ON_* objects as being inserted into and managed by
    ON_SimpleArray essentially as if they were C arrays of pointers, and
    that looks to be incorrect.  Good chance this is the root cause behind a
    lot of the more obscure memory issues clang static analyzer is finding
    with the various brep related codes...
    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    4cbf8f6 View commit details
    Browse the repository at this point in the history
  11. More adjustments to surfaceintersect arrays

    Previous problem wasn't quite what I thought - assignment was indeed
    making a full copy, so we also need to delete.  Also need a few more
    SimpleArray -> ClassArray switches.
    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    e332e80 View commit details
    Browse the repository at this point in the history
  12. This is triggering the static analyzer. Looking at the code it doesn'…

    …t seem to be in a working state and hasn't been worked on much since 2009.
    starseeker committed Nov 18, 2021
    Configuration menu
    Copy the full SHA
    dc86b84 View commit details
    Browse the repository at this point in the history

Commits on Nov 19, 2021

  1. Initialize

    starseeker committed Nov 19, 2021
    Configuration menu
    Copy the full SHA
    acf83f0 View commit details
    Browse the repository at this point in the history
  2. Initialize

    starseeker committed Nov 19, 2021
    Configuration menu
    Copy the full SHA
    3a179f3 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1bd0835 View commit details
    Browse the repository at this point in the history
  4. Initialize

    starseeker committed Nov 19, 2021
    Configuration menu
    Copy the full SHA
    645995d View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    e134864 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    0215ac6 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    537fbd9 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    26de902 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    5c03f52 View commit details
    Browse the repository at this point in the history
  10. Initialize

    starseeker committed Nov 19, 2021
    Configuration menu
    Copy the full SHA
    8086fb1 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    5d06c96 View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    f7baae4 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    372dd05 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    e675979 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    e05c7f4 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    c9268c1 View commit details
    Browse the repository at this point in the history
  17. Start looking at libutahrle's clang reports - may as well see how man…

    …y we can clear by a combination of trimming and small changes.
    starseeker committed Nov 19, 2021
    Configuration menu
    Copy the full SHA
    adb6736 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    9664761 View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    166c6d9 View commit details
    Browse the repository at this point in the history

Commits on Nov 20, 2021

  1. free memory

    starseeker committed Nov 20, 2021
    Configuration menu
    Copy the full SHA
    446e5ab View commit details
    Browse the repository at this point in the history
  2. Looks like another of those cases where clang assumes something is fa…

    …lse and then later assumes it is true for no apparent reason... just add a null check.
    starseeker committed Nov 20, 2021
    Configuration menu
    Copy the full SHA
    7097d1a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    06d4c2b View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    7e7870e View commit details
    Browse the repository at this point in the history
  5. Initialize

    starseeker committed Nov 20, 2021
    Configuration menu
    Copy the full SHA
    b0e5b96 View commit details
    Browse the repository at this point in the history
  6. Clean up opbuf

    starseeker committed Nov 20, 2021
    Configuration menu
    Copy the full SHA
    da4c7e8 View commit details
    Browse the repository at this point in the history
  7. More memory freeing

    starseeker committed Nov 20, 2021
    Configuration menu
    Copy the full SHA
    3af1e88 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    7fe8df1 View commit details
    Browse the repository at this point in the history

Commits on Nov 22, 2021

  1. Configuration menu
    Copy the full SHA
    91b61a8 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    87366be View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    913384f View commit details
    Browse the repository at this point in the history
  4. Add more NULL checks.

    starseeker committed Nov 22, 2021
    Configuration menu
    Copy the full SHA
    140e800 View commit details
    Browse the repository at this point in the history
  5. Unused assignments.

    starseeker committed Nov 22, 2021
    Configuration menu
    Copy the full SHA
    072bdbd View commit details
    Browse the repository at this point in the history
  6. x is unused here, but I'm not 100% convinced that's correct. renderin…

    …g is working well enough, so not messing with this, but commenting it out rather than deleting it in case this does become an issue in the future.
    starseeker committed Nov 22, 2021
    Configuration menu
    Copy the full SHA
    2b79898 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    6033c4d View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    fb0c80d View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    627001c View commit details
    Browse the repository at this point in the history
  10. Watch analyzer results for osmesa, utahrle, polyt2ri

    Having gotten these clean (at least with clang 12), lets keep them that
    way.  utahrle doesn't have an active upstream, our poly2tri is
    significantly altered from the upstream version, and osmesa is an
    extraction of Mesa 7.0.4's OpenGL 2.1 software-only rasterizer - the
    current upstream code is now completely different.
    
    Realistically Tktable and Tkhtml (particularly Tkhtml) should also fall
    into this category, but they're not as trivial to set up in the test
    script since they may need Tcl/Tk built from src/other/ext first (and,
    unlike the other three libs, the Tk widgets should eventually be phased
    out in favor of Qt functionality anyway...)
    
    OpenNURBS is in a separate class - basically, unlike the other src/other
    libs not in ext, it does have an active upstream - we just need to
    maintain it in src/other because of the significant number of patches we
    apply to it.
    starseeker committed Nov 22, 2021
    Configuration menu
    Copy the full SHA
    7730251 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    14f2123 View commit details
    Browse the repository at this point in the history

Commits on Nov 23, 2021

  1. Remove unused variables

    starseeker committed Nov 23, 2021
    Configuration menu
    Copy the full SHA
    469ae22 View commit details
    Browse the repository at this point in the history
  2. More unused variables.

    starseeker committed Nov 23, 2021
    Configuration menu
    Copy the full SHA
    cf1bcb5 View commit details
    Browse the repository at this point in the history
  3. Try adding sentinel files to the perplex/lemon cpy

    Grr.  Getting random failures in the stepcode building, mostly on the
    Github runners but occasionally on normal desktops as well.  Symptoms
    are an internal operation of the stepcode build erring out complaining
    about not being able to do I/O on one of the files that needs to be
    copied, but when you check the file is there.  Historically that's
    happened when disk I/O isn't quite keeping up with processing or
    parallel operations end up colliding.
    
    Traditional solution has been to add sentinel files that are only
    created after the original operation is done.  See if that helps here.
    starseeker committed Nov 23, 2021
    Configuration menu
    Copy the full SHA
    b698016 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    1365fc7 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    08b828f View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    d8d0abb View commit details
    Browse the repository at this point in the history

Commits on Nov 28, 2021

  1. Fix distclean name.

    starseeker committed Nov 28, 2021
    Configuration menu
    Copy the full SHA
    79ff1d3 View commit details
    Browse the repository at this point in the history

Commits on Nov 29, 2021

  1. Remove unused variables.

    starseeker committed Nov 29, 2021
    Configuration menu
    Copy the full SHA
    a5f127b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8a7abeb View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    4b5b4c0 View commit details
    Browse the repository at this point in the history
  4. Don't need tk.h here

    starseeker committed Nov 29, 2021
    Configuration menu
    Copy the full SHA
    ae5c88b View commit details
    Browse the repository at this point in the history
  5. Contain librt exposure with libdm headers

    Including librt headers pulls in openNURBS, which has a lot of
    implications for things like needing warning suppressed.  Use an ifdef
    guard to only expose and use these functions where necessary to limit
    the scope of the necessary adjustment.
    starseeker committed Nov 29, 2021
    Configuration menu
    Copy the full SHA
    d8b5e6c View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    fd8f40b View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    4e05e4f View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    482be08 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    7b66aef View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    859116e View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    b09bd5e View commit details
    Browse the repository at this point in the history

Commits on Nov 30, 2021

  1. Simplify static analysis script

    With the count down, it's no longer as beneficial to separate things out
    into per-library reports - just assemble a single report for the all
    target, and use the total report count as a criteria for failure - like
    our other checks, if the count rises over the current known rate report
    failure.  We'll lower the number as issues are resolved.
    starseeker committed Nov 30, 2021
    Configuration menu
    Copy the full SHA
    c103fc4 View commit details
    Browse the repository at this point in the history

Commits on Dec 1, 2021

  1. Configuration menu
    Copy the full SHA
    2f80d89 View commit details
    Browse the repository at this point in the history
  2. Messed up the memory allocation sizes needed when adjusting the types…

    … when trying to satisfy the static analyzer - revert until the correct change is set up.
    starseeker committed Dec 1, 2021
    Configuration menu
    Copy the full SHA
    f08604d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    894ccbe View commit details
    Browse the repository at this point in the history
  4. Reapply the type matching, but this time correct the overall allocati…

    …on size for the two previously using int.
    starseeker committed Dec 1, 2021
    Configuration menu
    Copy the full SHA
    1ebbf2a View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    f03f0e2 View commit details
    Browse the repository at this point in the history
  6. apply a fix upstream already has

    libtclstub ends up with an unresolved symbol as TclIsSpaceProc is not available in the stub lib.  this causes mac build to fail hard on anything linking the stub lib (like tk).
    brlcad committed Dec 1, 2021
    Configuration menu
    Copy the full SHA
    819644c View commit details
    Browse the repository at this point in the history

Commits on Dec 7, 2021

  1. Ah - at least with clang 12 on Linux, the compiler test needs -lasan …

    …for the flag test to succeed. Leaving commented out as actually enabling the flag appears to cause breakage.
    starseeker committed Dec 7, 2021
    Configuration menu
    Copy the full SHA
    95f242b View commit details
    Browse the repository at this point in the history
  2. Add some env2c workaround logic for -lasan

    Well this is wacky... apparently adding the -fsanitize=address flag
    changes the results of the FindThreads test, causing it to not add
    -lpthread. If we don't use the flag consistently everywhere after we
    start using that flag the address+Threads result will break independent
    logic that's not using the -fsanatize setting.
    starseeker committed Dec 7, 2021
    Configuration menu
    Copy the full SHA
    401cc9d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    df457c5 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    d3a45e1 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    c59a9d0 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    2786f75 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    c937aaa View commit details
    Browse the repository at this point in the history

Commits on Dec 8, 2021

  1. Configuration menu
    Copy the full SHA
    b6625e0 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    0f4c9e6 View commit details
    Browse the repository at this point in the history
  3. Clean up avs container

    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    8c23b6a View commit details
    Browse the repository at this point in the history
  4. More memory cleanup

    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    6a61b42 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    7bfd084 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    1e9c649 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    a9988fc View commit details
    Browse the repository at this point in the history
  8. Hide AddressSanitizer flags behind an option

    We don't want this to accidentally activate if -lasan is no longer a
    requirement someday - BRL-CAD's code isn't ready for it yet.  In
    particular, the LeakSanitizer trips up on the rt_free_rti/rt_clean
    tangle as well as _db_walk_subtree.  The former may need elimination of
    the rt_uniresource global to properly clean up, and the latter is deep
    in the raytracing core and will have to be approached very carefully.
    
    For convenience, here are the backtraces:
    
    889: Test command: build/bin/gqa "-P" "1" "-Ao" "-p" "ovlp_" "brlcad/src/gtools/tests/../../libged/tests/ged_tests.g" "ovlp"
    889: Test timeout computed to be: 1500
    889: Trying initial grid spacing: 50 mm
    889: Using grid spacing lower limit: 0.005 mm
    889: Plotting overlaps to ovlp_overlaps.plot3
    889: Processing with grid spacing 50 mm 44 x 48 x 39
    889: Summary (50mm grid spacing):
    889: list Overlaps:
    889: /ovlp/r1 /ovlp/r2 count:2277 dist:1780.3mm @ (-248 350 -903.325)
    889:
    889: =================================================================
    889: ==672620==ERROR: LeakSanitizer: detected memory leaks
    889:
    889: Direct leak of 524288 byte(s) in 1024 object(s) allocated from:
    889:     #0 0x498087 in posix_memalign (build/bin/gqa+0x498087)
    889:     #1 0x7f9d3ca476c3 in alloc brlcad/src/libbu/malloc.c:137:10
    889:     #2 0x7f9d3ca478f6 in bu_calloc brlcad/src/libbu/malloc.c:174:12
    889:     #3 0x7f9d3ca9b25e in bu_ptbl_init brlcad/src/libbu/ptbl.c:45:26
    889:     #4 0x7f9d40d38be4 in rt_init_resource brlcad/src/librt/prep.c:855:2
    889:     #5 0x7f9d40d3ba65 in rt_clean_resource brlcad/src/librt/prep.c:1063:5
    889:     #6 0x7f9d40d3239a in rt_clean brlcad/src/librt/prep.c:1210:6
    889:     #7 0x7f9d40d30f80 in rt_free_rti brlcad/src/librt/prep.c:170:5
    889:     #8 0x7f9d380c4573  (<unknown module>)
    889:     #9 0x7f9d424f2526 in ged_exec brlcad/src/libged/exec.cpp:83:16
    889:     #10 0x7f9d424fd51b in ged_gqa brlcad/src/libged/exec_mapping.cpp:177:1
    889:     #11 0x4c8b17 in main brlcad/src/gtools/gqa.c:105:11
    889:     #12 0x7f9d3c6be0b2 in __libc_start_main /build/glibc-eX1tMB/glibc-2.31/csu/../csu/libc-start.c:308:16
    889:
    889: Direct leak of 524288 byte(s) in 1024 object(s) allocated from:
    889:     #0 0x498087 in posix_memalign (build/bin/gqa+0x498087)
    889:     #1 0x7f9d3ca476c3 in alloc brlcad/src/libbu/malloc.c:137:10
    889:     #2 0x7f9d3ca478f6 in bu_calloc brlcad/src/libbu/malloc.c:174:12
    889:     #3 0x7f9d3ca9b25e in bu_ptbl_init brlcad/src/libbu/ptbl.c:45:26
    889:     #4 0x7f9d40d38c65 in rt_init_resource brlcad/src/librt/prep.c:858:2
    889:     #5 0x7f9d380c0db2  (<unknown module>)
    889:     #6 0x7f9d424f2526 in ged_exec brlcad/src/libged/exec.cpp:83:16
    889:     #7 0x7f9d424fd51b in ged_gqa brlcad/src/libged/exec_mapping.cpp:177:1
    889:     #8 0x4c8b17 in main brlcad/src/gtools/gqa.c:105:11
    889:     #9 0x7f9d3c6be0b2 in __libc_start_main /build/glibc-eX1tMB/glibc-2.31/csu/../csu/libc-start.c:308:16
    889:
    889: Direct leak of 64 byte(s) in 2 object(s) allocated from:
    889:     #0 0x498087 in posix_memalign (build/bin/gqa+0x498087)
    889:     #1 0x7f9d3ca476c3 in alloc brlcad/src/libbu/malloc.c:137:10
    889:     #2 0x7f9d3ca478f6 in bu_calloc brlcad/src/libbu/malloc.c:174:12
    889:     #3 0x7f9d40ce3610 in _db_walk_subtree brlcad/src/librt/db_tree.c:1914:6
    889:     #4 0x7f9d40cdd664 in _db_walk_dispatcher brlcad/src/librt/db_tree.c:1992:2
    889:     #5 0x7f9d3ca795da in bu_parallel brlcad/src/libbu/parallel.c:574:2
    889:     #6 0x7f9d40cdc2a2 in db_walk_tree brlcad/src/librt/db_tree.c:2199:5
    889:     #7 0x7f9d41893a86 in rt_gettrees_muves brlcad/src/librt/tree.c:779:6
    889:     #8 0x7f9d4189bb3f in rt_gettrees_and_attrs brlcad/src/librt/tree.c:883:12
    889:     #9 0x7f9d4189bcba in rt_gettree brlcad/src/librt/tree.c:896:11
    889:     #10 0x7f9d380c0e88  (<unknown module>)
    889:     #11 0x7f9d424f2526 in ged_exec brlcad/src/libged/exec.cpp:83:16
    889:     #12 0x7f9d424fd51b in ged_gqa brlcad/src/libged/exec_mapping.cpp:177:1
    889:     #13 0x4c8b17 in main brlcad/src/gtools/gqa.c:105:11
    889:     #14 0x7f9d3c6be0b2 in __libc_start_main /build/glibc-eX1tMB/glibc-2.31/csu/../csu/libc-start.c:308:16
    889:
    889: Direct leak of 64 byte(s) in 2 object(s) allocated from:
    889:     #0 0x498087 in posix_memalign (build/bin/gqa+0x498087)
    889:     #1 0x7f9d3ca476c3 in alloc brlcad/src/libbu/malloc.c:137:10
    889:     #2 0x7f9d3ca478f6 in bu_calloc brlcad/src/libbu/malloc.c:174:12
    889:     #3 0x7f9d40c2a4bc in rt_comb_import5 brlcad/src/librt/comb/comb.c:518:6
    889:     #4 0x7f9d40c79613 in rt_db_external5_to_internal5 brlcad/src/librt/db5_io.c:958:8
    889:     #5 0x7f9d40c79e9f in rt_db_get_internal5 brlcad/src/librt/db5_io.c:998:11
    889:     #6 0x7f9d40ce6b76 in rt_db_get_internal brlcad/src/librt/dir.c:131:9
    889:     #7 0x7f9d40cd31b4 in db_recurse brlcad/src/librt/db_tree.c:1016:6
    889:     #8 0x7f9d40ce34ee in _db_walk_subtree brlcad/src/librt/db_tree.c:1898:16
    889:     #9 0x7f9d40cdd664 in _db_walk_dispatcher brlcad/src/librt/db_tree.c:1992:2
    889:     #10 0x7f9d3ca795da in bu_parallel brlcad/src/libbu/parallel.c:574:2
    889:     #11 0x7f9d40cdc2a2 in db_walk_tree brlcad/src/librt/db_tree.c:2199:5
    889:     #12 0x7f9d41893a86 in rt_gettrees_muves brlcad/src/librt/tree.c:779:6
    889:     #13 0x7f9d4189bb3f in rt_gettrees_and_attrs brlcad/src/librt/tree.c:883:12
    889:     #14 0x7f9d4189bcba in rt_gettree brlcad/src/librt/tree.c:896:11
    889:     #15 0x7f9d380c0e88  (<unknown module>)
    889:     #16 0x7f9d424f2526 in ged_exec brlcad/src/libged/exec.cpp:83:16
    889:     #17 0x7f9d424fd51b in ged_gqa brlcad/src/libged/exec_mapping.cpp:177:1
    889:     #18 0x4c8b17 in main brlcad/src/gtools/gqa.c:105:11
    889:     #19 0x7f9d3c6be0b2 in __libc_start_main /build/glibc-eX1tMB/glibc-2.31/csu/../csu/libc-start.c:308:16
    889:
    889: SUMMARY: AddressSanitizer: 1048704 byte(s) leaked in 2052 allocation(s).
    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    3e593d9 View commit details
    Browse the repository at this point in the history
  9. CMake, not C++...

    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    a2622d8 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    82003f4 View commit details
    Browse the repository at this point in the history
  11. This is user visible - bot_merge won't segfault now when handed bots …

    …of different types (like bot_merge merged.bot *.t0 in the FAA Generic_Twin example.)
    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    dea11d2 View commit details
    Browse the repository at this point in the history
  12. Unused variables.

    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    dc52ca6 View commit details
    Browse the repository at this point in the history
  13. More unused variables.

    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    b7d1c45 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    a3c4746 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    e32e4b7 View commit details
    Browse the repository at this point in the history
  16. With ged_close cleaning up after ged_open, remove manual BU_PUT calls…

    … cleaning up gedp in various places.
    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    1d0314e View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    193bedb View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    fadc43f View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    f9e7b28 View commit details
    Browse the repository at this point in the history
  20. Configuration menu
    Copy the full SHA
    0572bc4 View commit details
    Browse the repository at this point in the history
  21. Configuration menu
    Copy the full SHA
    a90ba0c View commit details
    Browse the repository at this point in the history
  22. Configuration menu
    Copy the full SHA
    10def9e View commit details
    Browse the repository at this point in the history
  23. Configuration menu
    Copy the full SHA
    613f32f View commit details
    Browse the repository at this point in the history
  24. Configuration menu
    Copy the full SHA
    c7fc05a View commit details
    Browse the repository at this point in the history
  25. Handle a corner case in bu_argv_free where we have an array allocated…

    … but no contents - we still need to free the argv container.
    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    de30936 View commit details
    Browse the repository at this point in the history
  26. Make the fb names static, to match dm names

    Oof.  Writing down the details on this one, as I doubt I'll remember...
    
    The start was turning on both the AddressSanitizer and Qt.  When doing
    so, most programs suddenly began reporting memory leaks.  However, the
    report was rather cryptic, being four entries similar to this one:
    
    ==1262202==ERROR: LeakSanitizer: detected memory leaks
    
    Direct leak of 21 byte(s) in 1 object(s) allocated from:
        #0 0x498087 in posix_memalign (build/src/libdm/tests/dm_test+0x498087)
        #1 0x7f4e90e53675 in alloc brlcad/src/libbu/malloc.c:129:10
        #2 0x7f4e90e53400 in bu_malloc brlcad/src/libbu/malloc.c:167:12
        #3 0x7f4e90ee1c02 in bu_strdupm brlcad/src/libbu/str.c:165:17
        #4 0x7f4e87dcd3e9  (<unknown module>)
        #5 0x7f4e87dcdea5  (<unknown module>)
        #6 0x7f4e9650eb89  (/lib64/ld-linux-x86-64.so.2+0x11b89)
    
    I wasn't immediately sure if the unknown module error was related to the
    plugin loading, and spent a lot of time trying to find a string memory
    issue in dm_init.cpp.  After that proved fruitless, other than to
    confirm that the error disappeared if i removed the bu_dlclose-ing of
    the handles saved at initialization, I began to look for ways to decode
    the "unknown module" entries.  That led to the following issue:
    google/sanitizers#89 which describes the
    problem ASan has with dynamic libraries.  Comments indicated that it
    would see real issues, but won't report which dynamic library they come
    from (and there are no plans to fix this anytime soon... grr...).  In
    fairness, valgrind can see the error too but also has the same reporting
    problem; it appears to be ubiquitous.
    
    Fortunately, we have an alternative due to the way our plugin system and
    test apps work - we can simply add and remove .so files to the directory
    and see how the error reporting changes to zero in on which file(s) are
    triggering the problem.  Doing so quickly made apparent what should have
    been obvious in retrospect - two of the errors each were coming from the
    Qt and swrast plugins, which had been off in earlier testing.
    
    Since there was no backtrace beyond the bu_strdupm call itself, and
    there were two errors per file, the suspect was the bu_strdup calls
    initializing the "char *" names for the fb structures.  The C files use
    static strings (which is why the non-Qt plugins didn't show the issue),
    but C++ doesn't tolerate the type mismatch.  The original hack
    workaround was just to bu_strdup and create a (char *) string, but as
    the leak detectors correctly note this also means there's no way to
    clean up the allocated memory.
    
    As far as I can tell there is no reason for these strings to be editable
    (char *) strings - the dm container's equivalents are static.  This
    commit removes any logic assuming if_name is dynamic, and also removes
    the bu_strdup hack from Qt and swrast.
    starseeker committed Dec 8, 2021
    Configuration menu
    Copy the full SHA
    046f47b View commit details
    Browse the repository at this point in the history
  27. Configuration menu
    Copy the full SHA
    219f02c View commit details
    Browse the repository at this point in the history

Commits on Dec 9, 2021

  1. Use dm_open to pair with the dm_close call in finish - dm_set_null do…

    …esn't work when we do that.
    starseeker committed Dec 9, 2021
    Configuration menu
    Copy the full SHA
    ac5f006 View commit details
    Browse the repository at this point in the history

Commits on Dec 10, 2021

  1. CID 1488714 - using pointer to individual char as string array

    db_str2op expects a NULL terminated const char * array - it skips
    leading whitespace with a while(*str) loop, so it needs to know when to
    stop.  Use null terminated strings as input instead of pointers to
    individual chars.
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    0c7474d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8915338 View commit details
    Browse the repository at this point in the history
  3. Clean up some memory inside the lemon parser.

    CID 280107, 280144.  A quick trial indicates that we'll need other
    changes if we update lemon.c and lempar.c to the latest upstream
    versions, so for now just mod our copies to free the memory.
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    8d40c75 View commit details
    Browse the repository at this point in the history
  4. Close fp if we need to bail early

    CID 481205
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    b66ae17 View commit details
    Browse the repository at this point in the history
  5. Close fp when returning due to error condition

    CID 490501
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    4e2917d View commit details
    Browse the repository at this point in the history
  6. Sanity check inputs

    CID 500450
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    b05c317 View commit details
    Browse the repository at this point in the history
  7. Sanity check yyruleno value

    CID 1127262.  If I'm understanding this correctly, Coverity is spotting
    the bounds check in the debug printing statement, interpreting this as
    an indication that yyruleno might exceed the array size, and (assuming
    that's true) then points out that if yyruleno CAN do that it would
    result in a problem when the array contents are accessed later on.
    
    Just do the check up front, to make sure we don't get into this logic
    with a problematic yyruleno, and warn if we hit it.  Not sure if the
    debugging logic was doing this check on general principles or they had
    an issue at some point...
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    1194161 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    330c2ed View commit details
    Browse the repository at this point in the history
  9. Validate size and allocation separately

    CID 1309088  Memory wasn't getting freed correctly in the error case -
    separate out the checks so we can do the right thing in each case.
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    d7639c9 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    5d707bd View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    157836a View commit details
    Browse the repository at this point in the history
  12. Leave room for a terminating NULL

    CID 1487591
    starseeker committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    2d934df View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    896763d View commit details
    Browse the repository at this point in the history

Commits on Dec 11, 2021

  1. Configuration menu
    Copy the full SHA
    4eb337e View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    30bc254 View commit details
    Browse the repository at this point in the history

Commits on Dec 13, 2021

  1. adding 1 to the buffer is contrary to the meaning of BUFSIZ.

    follow the same pattern used throughout the file. manually
    nul-terminating after copying into the buffer.
    brlcad committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    669e20a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cab40b1 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    7c4b887 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    7f8e8c9 View commit details
    Browse the repository at this point in the history
  5. going through db_str2op() is silly when the type is known.

    putting in the appropriate WMOP really makes it evident that the ops may be wrong too
    based on the nearby logic and comments.  leaving a FIXME note instead of updating, though
    as not set up to test changing it.
    brlcad committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    8956fb4 View commit details
    Browse the repository at this point in the history
  6. Check for null dmp inputs.

    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    a3f206c View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    a781547 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    1966c54 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    ce71407 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    6b479fc View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    3fe865f View commit details
    Browse the repository at this point in the history
  12. Call bu_dlclose to clean up the bu_dlopen handles

    CID 1487593 - without a way to clean up the dlopen handles, we're
    leaking resources.  Error cases are simple - just close before returning
    - but if we want to persist the successful handles until we're done
    converting we need to be able to stash them in the context.
    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    aa35a09 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    f26440b View commit details
    Browse the repository at this point in the history
  14. Fix gcv option handling, get regress-dem working

    Option handling was broken in gcv, and the target name was wrong for
    enabling the GDAL test for converting a dem file.
    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    ea1607c View commit details
    Browse the repository at this point in the history
  15. Adjust vrml parser memory management, add test

    CID 1487599 - creating a new node and then immediately overwriting it
    with createNewNode was leaking memory.  While we're at it, add a basic
    regression test to make sure the VRML conversion plugin runs.
    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    6f595ab View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    50ceda9 View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    7204511 View commit details
    Browse the repository at this point in the history
  18. Free leaked storage

    CID 1487624 - If I understand this correctly, Coverity is indicating
    that this resource is copied rather than pointed to, and thus we need to
    be freeing it locally.
    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    f05bdba View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    3942b19 View commit details
    Browse the repository at this point in the history
  20. Null out pointer after freeing

    CID 1487628 - prompted by this, but not 100% this is the fix...
    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    48a3cd8 View commit details
    Browse the repository at this point in the history
  21. Configuration menu
    Copy the full SHA
    ca6c61f View commit details
    Browse the repository at this point in the history
  22. Initialize sign value

    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    75295d8 View commit details
    Browse the repository at this point in the history
  23. Report count is down to 19

    starseeker committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    562e9bd View commit details
    Browse the repository at this point in the history

Commits on Dec 14, 2021

  1. Free pathbuf in all cases, not just inside the if

    CID 718529 - need to free pathbuf even if path == NULL.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    233a34a View commit details
    Browse the repository at this point in the history
  2. Supply destructor for CmdMgr

    CID 1487662 CmdMgr constructor allocates memory witn hew, but didn't
    have a destructor to free it.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    e240082 View commit details
    Browse the repository at this point in the history
  3. Don't return pointers to local arrays

    CID 1487674 - function was returning a pointer to locally scoped arrays,
    which means the caller would have no guarantee that the contents would
    remain correct.  Make the arrays static, since they are are supplying
    fixed definitions that will not change for the life of the program.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    9d079ed View commit details
    Browse the repository at this point in the history
  4. Add a few operators and methods to classes

    Since we're using C++ containers and copying for these (at least for the
    moment) it looks like Coverity is setting some issues with uninitialized
    data.  Not sure if this is the answer, but it's at least a little more
    explicit about the intent.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    758c633 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    2edf7e9 View commit details
    Browse the repository at this point in the history
  6. Clean up 'solution' in SPSR.

    CID 1488258
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    d756125 View commit details
    Browse the repository at this point in the history
  7. Adjust maximum count for MarchingSquares

    CID 1487686 - Coverity reporting that MarchingSquares::vertexList in
    SetVertex has size 4, but the loop was going to 11.  At a guess the 12
    limit may have come from the edge count of a cube, not a square...
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    1dbab78 View commit details
    Browse the repository at this point in the history
  8. Clean up CDT if we are exiting early

    CID 1495127
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    b6187b2 View commit details
    Browse the repository at this point in the history
  9. Fix type in bn_htov_move

    CID 1489008
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    66e6c60 View commit details
    Browse the repository at this point in the history
  10. struct -> class

    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    e7d9615 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    f38790e View commit details
    Browse the repository at this point in the history
  12. Check for fd < 0

    CID 1487956 - Resource leak reported by Coverity if testing fd <= 0 and
    fd == 0.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    af7478f View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    8d25f2f View commit details
    Browse the repository at this point in the history
  14. clr was getting used out of scope - move it

    CID 1488379
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    35e37de View commit details
    Browse the repository at this point in the history
  15. If reading the man page correctly, fd==0 is valid

    CID 1488673 Resource leak when fd == 0
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    3f3cbdc View commit details
    Browse the repository at this point in the history
  16. Supply array in case it is needed

    CID 1495209 - this may be a false positive in that the set of possible
    keys doesn't seem to include the GL_MODELVIEW_MATRX case, but go ahead
    and supply it anyway.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    b15ae8d View commit details
    Browse the repository at this point in the history
  17. Can't do this for the i == 0 case

    CID 1495029 If we're already at the lowest index, [i-1] doesn't work
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    c5b49db View commit details
    Browse the repository at this point in the history
  18. Increase array sizes

    CID 1494821, CID 1494747 - looping using VBO_ATTRIB_FIRST_MATERIAL as an
    index limit, which is defined as 32, not 16.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    22b5bc2 View commit details
    Browse the repository at this point in the history
  19. Parse_ScalarConstant needs an array

    CID 1495078 - Parse_ScalarConstant's numerical path assigns the number
    to four slots in an array, but as the caller incremented the available
    output array got smaller - result, Out-of-bounds access if the numerical
    case activated.  Rather than passing in vec directly, use a temporary
    array so Parse_ScalarConstant has enough room.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    be85013 View commit details
    Browse the repository at this point in the history
  20. Don't call _mesa_free if prog is set to the dummy

    CID: 501626
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    ac1c76c View commit details
    Browse the repository at this point in the history
  21. Correct parameter passed by _mesa_TexEnvfv

    CID: 1494906  Do here what is done for _mesa_TexEnvfi and provide a
    large enough array to pass to the next function.
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    0ff04b2 View commit details
    Browse the repository at this point in the history
  22. Another out-of-bounds correction

    CID 1494889
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    9011c04 View commit details
    Browse the repository at this point in the history
  23. More out-of-bounds corrections

    CID 1494720
    CID 1494859
    CID 1494865
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    1956eac View commit details
    Browse the repository at this point in the history
  24. Zero inputs don't work very well here

    CID 500450
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    b469e8b View commit details
    Browse the repository at this point in the history
  25. More out-of-bounds access adjustments

    CID 1494924
    CID 1495118
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    8b969b9 View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    0a07c03 View commit details
    Browse the repository at this point in the history
  27. Ensure we're not beyond Attachment array size

    CID 714349 - this probably indicates some other issue, since these are
    all constants and I wouldn't expect any invalid combinations...
    starseeker committed Dec 14, 2021
    Configuration menu
    Copy the full SHA
    7df397f View commit details
    Browse the repository at this point in the history

Commits on Dec 15, 2021

  1. Initialize

    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    8c42148 View commit details
    Browse the repository at this point in the history
  2. make sure we free the correct memory

    CID 1495416: pathbuf may get assigned a different value during
    processing, so use a local variable to ensure we always free what was
    originally malloced.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    71510f1 View commit details
    Browse the repository at this point in the history
  3. Remove invalid free

    CID 1487777 Per Coverity, free of address-of expression: moveTrisToNodes
    frees incorrect pointer root.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    4018881 View commit details
    Browse the repository at this point in the history
  4. Null out vars and sanity check in bspline.cpp

    CID 1488304 and probably a few others... Use after free errors.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    f94be05 View commit details
    Browse the repository at this point in the history
  5. Don't allocate the brep until we have a valid op

    CID 1494693
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    5d23753 View commit details
    Browse the repository at this point in the history
  6. Free gdiam memory after bbox work is done

    CID 1488409
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    2c32dea View commit details
    Browse the repository at this point in the history
  7. Use local variables for the object arrays

    CID 1489147 - had a free call where we didn't need it.  obj_array
    appears to function locally within each block, so use local variables to
    help avoid introducing this issue.  I suspect we aren't cleaning up the
    memory fully in all cases here...
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    f021a00 View commit details
    Browse the repository at this point in the history
  8. Make new_planes a local variable, validate parsing

    CID 1488895 - commit prompted by this issue, but not 100% sure this is
    the fix.  Looks like multiple loops are hitting a case where arbn->eqn
    and new_planes contain the same pointer, but not immediately obvious
    what's prompting that.  First guess is something stale in the new_plane
    pointer, which was defined at the top level function scope, so bringing
    it local to make behavior clearer.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    ba014d9 View commit details
    Browse the repository at this point in the history
  9. Use the %p specifier (standard) to print pointers

    CID 1488175 is indicating pc->pkc_inbuf isn't NULL terminated because
    it's contents come from read (which is true) and therefore snprintf has
    a problem with it.  That would be true if we were trying to print the
    pkc_inbuf contents as a string, but I think the intent here is to print
    pointers, which should make NULL termination moot.  (Printing the
    pointers here is of questionable utility, but that's another
    discussion...)  See if using %p is more acceptable to Coverity.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    80ec646 View commit details
    Browse the repository at this point in the history
  10. Invalid bu_free

    CID 1488979 - tt_name is a 64 char array in the struct, not a dynamic
    string.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    c1738ed View commit details
    Browse the repository at this point in the history
  11. Use the correct free function for this vls

    CID 1488030 - using the function that frees the vls contents and the vls
    container, but we just need the contents here.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    013f2a1 View commit details
    Browse the repository at this point in the history
  12. Make sure we never get to BLADE_MAX

    CID 1488594 I think this might be a false positive, as CLAMP should be
    keeping pl->blades within bounds, but go ahead and also make sure blade
    never gets to BLADE_MAX to see if that helps.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    87b6cf2 View commit details
    Browse the repository at this point in the history
  13. Close fd if we got it from a file

    CID 1487758 - Need to close fd if we got it from open()
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    ac087ee View commit details
    Browse the repository at this point in the history
  14. void cast for %p

    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    4d05202 View commit details
    Browse the repository at this point in the history
  15. We already did analyze_densities_destroy earlier

    CID 1488378
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    93baa66 View commit details
    Browse the repository at this point in the history
  16. Close outfile if we're erroring out

    CID 1487860
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    98548fd View commit details
    Browse the repository at this point in the history
  17. Don't do nmg cleanup until after we're done with s

    CID 1489196
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    5cf4f84 View commit details
    Browse the repository at this point in the history
  18. dbName is already zero initialized

    CID 1488507
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    31189e1 View commit details
    Browse the repository at this point in the history
  19. Refactor the char->op portion of db_str2op

    CID 1488217 If we are representing booleans with a single char, need a
    more convenient way to get the corresponding db_opt_t to avoid getting
    into trouble with out-of-bounds access issues.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    d4d2d45 View commit details
    Browse the repository at this point in the history
  20. Off by one in looping limit

    CID 1487984
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    218a7dd View commit details
    Browse the repository at this point in the history
  21. fclose fp if we're returning early.

    CID 1488894
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    f332f58 View commit details
    Browse the repository at this point in the history
  22. Close fp if fread doesn't work

    CID 1487801
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    411367a View commit details
    Browse the repository at this point in the history
  23. Need buf to be big enough for 3 channels

    CID 1488266 fb_rect.c:158 - overrunning array of 24576 bytes at byte
    offset 73725
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    0a486a9 View commit details
    Browse the repository at this point in the history
  24. Missed a bu_dlclose

    CID 1494729
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    e7c8c5e View commit details
    Browse the repository at this point in the history
  25. close fd after we're done with it

    CID 1488415
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    dc1a3f6 View commit details
    Browse the repository at this point in the history
  26. Just use fread results rather than strlen

    CID 1488493 Coverity doesn't like doing strlen on the fread results due
    to possibly not being NULL terminated.  I think this may be a false
    positive?  I would expect the memset on the buffer to give us a
    guaranteed null at buf[BUFFER_SIZE]...
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    3d8db37 View commit details
    Browse the repository at this point in the history
  27. Only need to free tbasename once

    CID 1495191
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    1e8fe96 View commit details
    Browse the repository at this point in the history
  28. Close dl_handle for error cases

    CID 1494773
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    20d7857 View commit details
    Browse the repository at this point in the history
  29. close fd in error case

    CID 1487921
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    246db54 View commit details
    Browse the repository at this point in the history
  30. Coverity doesn't like overwriting the dup outputs

    CID 1487884
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    3f29e9f View commit details
    Browse the repository at this point in the history
  31. Handle stash->connection being closed by err case

    CID 1488763 If stash->connection is already closed, don't keep working
    with it.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    4f0328e View commit details
    Browse the repository at this point in the history
  32. Tighten check for high LZW code

    CID 1488494 - if c == next_code == 4096, then Expand(c) triggers an
    OVERRUN condition.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    741364e View commit details
    Browse the repository at this point in the history
  33. Hmm. c >= next_code results in some gif displays that previously work…

    …ed failing. Try increasing table size, and use bu_log to print the error code (Message is mangling the number)
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    9a3e665 View commit details
    Browse the repository at this point in the history
  34. Configuration menu
    Copy the full SHA
    497b760 View commit details
    Browse the repository at this point in the history
  35. Merge pull request #8 from treydinges/chris-appleseed-cmake-update

    Update to art with a slew of significant changes from Chris McGregor
    
    This adds support for the set command to control the number of samples, it lets are utilize OSL shaders from appleseed that are set on objects via material objects (optical "OSL" property), and it should support most of the RTUIF commands (e.g., az/el) although the code was reverted to a +y coordinate frame which results in a 90-degree rotated output image.  Most significant in this pull is the conversion to registering each region individually as an appleseed object, so material properties and color can be applied per-object.  There is one big performance-impacting hack in the code -- a per ray string comparison.  Current librt rt_shootray() hit callback is initialized with the whole scene, but needs to report only hits for a single specific object at a time.  Hack was to check if it's the right object by way of a string path-to-region comparison.  Needs separate per-object rtip's or a numeric handle (e.g., pointer) to each region otherwise (depending on whether we think librt or appleseed's spatial partitioning is faster).  Outstanding work from Chris.
    brlcad authored Dec 15, 2021
    Configuration menu
    Copy the full SHA
    3a3daba View commit details
    Browse the repository at this point in the history
  36. output.c_str() is a problem when scope changes

    CID 1488969 - Per Coverity: internal representation of local output
    escapes into output_file, but is destroyed when it exits scope.  Make a
    C copy of the string for subsequent use, and free it when no longer
    needed.
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    27f2ede View commit details
    Browse the repository at this point in the history
  37. Configuration menu
    Copy the full SHA
    cf618d7 View commit details
    Browse the repository at this point in the history
  38. Free bounding box in the error case

    CID 1494811
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    76a9775 View commit details
    Browse the repository at this point in the history
  39. Free select_list in error case

    CID 1488659
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    bdac4a7 View commit details
    Browse the repository at this point in the history
  40. Free char_def_prod once we are done with it

    CID 1489084 - resource leak
    starseeker committed Dec 15, 2021
    Configuration menu
    Copy the full SHA
    b767743 View commit details
    Browse the repository at this point in the history