]> granicus.if.org Git - graphviz/commit
neatogen: fix miscalculation of intermediate edge resources
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Tue, 15 Nov 2022 04:36:15 +0000 (20:36 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Thu, 17 Nov 2022 04:03:16 +0000 (20:03 -0800)
commit41ddbf28e4a0558c6360ec170d463861b0a748b5
treed7eea759c63c70664f2cbe02940aa816d373610e
parentfc465488e1e62fe5ef879b379a07ef272431f400
neatogen: fix miscalculation of intermediate edge resources

`genroute` was allocating an array for edge computation upfront. But what it was
not accounting for was that some of the functions it later calls _change_ the
`pn` value it used to determine how many array elements it should allocate.
Specifically, `Pshortestpath` can add new points to the polygon, thereby causing
the walk of the (now too short) array to write out of bounds.

Gitlab: fixes #42
Reported-by: mattjj
CHANGELOG.md
lib/neatogen/multispline.c
tests/test_regression.py