]> granicus.if.org Git - graphviz/log
graphviz
4 years agoRemove 1 -Wunused-but-set-variable warning in compute_hierarchy.c
Magnus Jacobsson [Sat, 7 Nov 2020 12:50:00 +0000 (13:50 +0100)]
Remove 1 -Wunused-but-set-variable warning in compute_hierarchy.c

4 years agoRemove 2 -Wunused-but-set-variable warnings in dotsplines.c
Magnus Jacobsson [Sat, 7 Nov 2020 12:42:44 +0000 (13:42 +0100)]
Remove 2 -Wunused-but-set-variable warnings in dotsplines.c

4 years agoRemove 1 -Wunused-but-set-variable warning in aspect.c
Magnus Jacobsson [Sat, 7 Nov 2020 12:40:49 +0000 (13:40 +0100)]
Remove 1 -Wunused-but-set-variable warning in aspect.c

4 years agoFix handling of epsf file read error in psusershape.c
Magnus Jacobsson [Sat, 7 Nov 2020 12:39:54 +0000 (13:39 +0100)]
Fix handling of epsf file read error in psusershape.c

Also removes 1 -Wunused-but-set-variable warning

4 years agoRemove 4 -Wunused-function warnings in ns.c
Magnus Jacobsson [Sat, 7 Nov 2020 12:39:09 +0000 (13:39 +0100)]
Remove 4 -Wunused-function warnings in ns.c

4 years agoRemove 1 -Wunused-but-set-variable warning in dtview.c
Magnus Jacobsson [Sat, 7 Nov 2020 12:37:41 +0000 (13:37 +0100)]
Remove 1 -Wunused-but-set-variable warning in dtview.c

4 years agoMerge branch 'smattr/614456fd-ae2a-4243-93d1-e2fa5ee18cc0' into 'master'
Matthew Fernandez [Sun, 15 Nov 2020 01:09:06 +0000 (01:09 +0000)]
Merge branch 'smattr/614456fd-ae2a-4243-93d1-e2fa5ee18cc0' into 'master'

fix concentrate=true segfaults

Closes #1771 and #167

See merge request graphviz/graphviz!1664

4 years agoremove comparison against boolean literals in conc.c
Matthew Fernandez [Sun, 8 Nov 2020 23:03:57 +0000 (15:03 -0800)]
remove comparison against boolean literals in conc.c

4 years agoremove unnecessary bracketing in conc.c
Matthew Fernandez [Sun, 8 Nov 2020 23:02:55 +0000 (15:02 -0800)]
remove unnecessary bracketing in conc.c

4 years agofix: anticipate no non-normal edges when computing direction with concentrate
Matthew Fernandez [Sun, 8 Nov 2020 22:56:27 +0000 (14:56 -0800)]
fix: anticipate no non-normal edges when computing direction with concentrate

With concentrate enabled (`concentrate=true`), the direction of edges is
analyzed in lib/dotgen/conc.c. The loops in `samedir()` did not anticipate that
they may not find a single non-normal edge before hitting the end of an edge
chain. This change removes this assumption.

Fixes #167, #1771.

4 years agoMerge branch 'smattr/c15b6722-05d6-4d5f-9e5f-34bc637d7ad9' into 'master'
Matthew Fernandez [Sat, 14 Nov 2020 03:02:25 +0000 (03:02 +0000)]
Merge branch 'smattr/c15b6722-05d6-4d5f-9e5f-34bc637d7ad9' into 'master'

minor modernization in libvpsc

See merge request graphviz/graphviz!1662

4 years agoremove use of std::endl in VPSC
Matthew Fernandez [Sat, 7 Nov 2020 21:27:58 +0000 (13:27 -0800)]
remove use of std::endl in VPSC

Use of std::endl is generally considered an anti-pattern these days.

4 years agomake VPSC debugging code visible to the compiler
Matthew Fernandez [Sat, 7 Nov 2020 21:18:21 +0000 (13:18 -0800)]
make VPSC debugging code visible to the compiler

The compiler can still optimize this out, but this way we ensure it always stays
compilable and consistent with the surrounding code.

4 years agoremove unnecessary ifdef guards
Matthew Fernandez [Sat, 7 Nov 2020 20:45:40 +0000 (12:45 -0800)]
remove unnecessary ifdef guards

4 years agoMerge branch 'smattr/174FAE10-334A-4463-A0AD-FE61C51E45D8' into 'master'
Matthew Fernandez [Sat, 14 Nov 2020 02:32:47 +0000 (02:32 +0000)]
Merge branch 'smattr/174FAE10-334A-4463-A0AD-FE61C51E45D8' into 'master'

add a section of performance and profiling to dev docs

See merge request graphviz/graphviz!1661

4 years agoMerge branch 'smattr/134762F6-3732-49B2-A65D-FACE0D5BDAB6' into 'master'
Matthew Fernandez [Sat, 14 Nov 2020 02:20:11 +0000 (02:20 +0000)]
Merge branch 'smattr/134762F6-3732-49B2-A65D-FACE0D5BDAB6' into 'master'

removal of another setjmp/longjmp

See merge request graphviz/graphviz!1660

4 years agoremove some unnecessary bracketing
Matthew Fernandez [Sat, 7 Nov 2020 16:43:24 +0000 (08:43 -0800)]
remove some unnecessary bracketing

4 years agoreplace a malloc array allocation with calloc
Matthew Fernandez [Sat, 7 Nov 2020 16:37:45 +0000 (08:37 -0800)]
replace a malloc array allocation with calloc

This can be more efficient for large allocations and is generally cleaner code.

4 years agoremove some unnecessary casts of malloc return values
Matthew Fernandez [Sat, 7 Nov 2020 16:36:07 +0000 (08:36 -0800)]
remove some unnecessary casts of malloc return values

Some cases that were missed in e33fdf6d35f379bf53dc9656d07efba46077a617.

4 years agoremove a use of longjmp and use explicit return instead
Matthew Fernandez [Sat, 7 Nov 2020 16:32:22 +0000 (08:32 -0800)]
remove a use of longjmp and use explicit return instead

Related to #1801.

4 years agoMerge branch 'smattr/ea4ee7c7-8a0e-4f9f-bfdf-37e082768793' into 'master'
Matthew Fernandez [Thu, 12 Nov 2020 15:25:28 +0000 (15:25 +0000)]
Merge branch 'smattr/ea4ee7c7-8a0e-4f9f-bfdf-37e082768793' into 'master'

remove commented out code in Smyrna

See merge request graphviz/graphviz!1659

4 years agoadd a section of performance and profiling to dev docs
Matthew Fernandez [Sat, 7 Nov 2020 22:20:27 +0000 (14:20 -0800)]
add a section of performance and profiling to dev docs

4 years agoremove unused xdotstate, xdotstyle
Matthew Fernandez [Sat, 7 Nov 2020 16:06:56 +0000 (08:06 -0800)]
remove unused xdotstate, xdotstyle

4 years agoremove commented out code in Smyrna
Matthew Fernandez [Fri, 6 Nov 2020 04:12:26 +0000 (20:12 -0800)]
remove commented out code in Smyrna

4 years agoMerge branch 'smattr/4AE22380-A30F-4A49-B284-320A2BCDEBB2' into 'master'
Matthew Fernandez [Sat, 7 Nov 2020 04:10:31 +0000 (04:10 +0000)]
Merge branch 'smattr/4AE22380-A30F-4A49-B284-320A2BCDEBB2' into 'master'

fix buffer under-read in fdp

Closes #1290, #236, and #1865

See merge request graphviz/graphviz!1658

4 years agoremove some unnecessary brackets
Matthew Fernandez [Sun, 1 Nov 2020 03:17:23 +0000 (20:17 -0700)]
remove some unnecessary brackets

4 years agofix buffer under-read in fdp
Matthew Fernandez [Sun, 1 Nov 2020 02:41:27 +0000 (19:41 -0700)]
fix buffer under-read in fdp

When using fdp to process a graph, it would try to canonicalize all node names,
regardless of whether they were hosted in refstr_ts or not. The problem with
this is that the canonicalization logic assumes the character pointer passed
into it is within a refstr_t and that therefore it can do pointer subtraction to
get a pointer to the refstr_t itself. This was not true for internally
constructed node names like "%4".

We change this to always go through the refstr logic in agstrdup() when
canonicalizing names. This ensures that the pointer we pass into the
canonicalization logic *is* within a refstr_t. This is based on canon() in
lib/cgraph/output.c. Fixes #236, #1290, #1865.

4 years agoMerge branch 'smattr/c43d1d65-32e9-4049-a95f-9b209af13c66' into 'master'
Matthew Fernandez [Sat, 7 Nov 2020 02:10:12 +0000 (02:10 +0000)]
Merge branch 'smattr/c43d1d65-32e9-4049-a95f-9b209af13c66' into 'master'

fix: anticipate empty clusters when using newrank

Closes #1221

See merge request graphviz/graphviz!1657

4 years agosquash some unused parameter warnings
Matthew Fernandez [Sat, 31 Oct 2020 23:40:07 +0000 (16:40 -0700)]
squash some unused parameter warnings

4 years agoremove unused sg variable
Matthew Fernandez [Sat, 31 Oct 2020 23:39:56 +0000 (16:39 -0700)]
remove unused sg variable

4 years agosquash a -Wundef warning
Matthew Fernandez [Sat, 31 Oct 2020 23:39:43 +0000 (16:39 -0700)]
squash a -Wundef warning

4 years agoremove an unused parameter to mincross_clust()
Matthew Fernandez [Sat, 31 Oct 2020 23:39:26 +0000 (16:39 -0700)]
remove an unused parameter to mincross_clust()

4 years agoremove some unnecessary bracketing
Matthew Fernandez [Sat, 31 Oct 2020 23:03:03 +0000 (16:03 -0700)]
remove some unnecessary bracketing

4 years agointroduce an assertion on rank consistency
Matthew Fernandez [Sat, 31 Oct 2020 23:01:31 +0000 (16:01 -0700)]
introduce an assertion on rank consistency

Related to #1221.

4 years agofix: anticipate empty clusters when using newrank
Matthew Fernandez [Sat, 31 Oct 2020 22:42:05 +0000 (15:42 -0700)]
fix: anticipate empty clusters when using newrank

When using newrank=true and incorrectly putting a node in two clusters, one of
the clusters would end up empty. This broke assumptions in the crossing logic;
e.g. that all clusters have a leader. We fix this by detecting empty clusters
and removing them prior to the crossing logic. Fixes #1221.

4 years agoMerge branch 'smattr/119AD784-5E65-4421-BC9A-F772B4532C94' into 'master'
Matthew Fernandez [Sat, 7 Nov 2020 01:23:59 +0000 (01:23 +0000)]
Merge branch 'smattr/119AD784-5E65-4421-BC9A-F772B4532C94' into 'master'

fix: fclose(NULL) in the VRML plugin when current directory is not writable

Closes #793

See merge request graphviz/graphviz!1656

4 years agooptimize gvputs() usage in the VRML plugin
Matthew Fernandez [Sat, 31 Oct 2020 17:02:43 +0000 (10:02 -0700)]
optimize gvputs() usage in the VRML plugin

Combining these calls reduces the function call related overhead in this logic.

4 years agoremove an unnecessary unary +
Matthew Fernandez [Sat, 31 Oct 2020 16:38:52 +0000 (09:38 -0700)]
remove an unnecessary unary +

4 years agofix: fclose(NULL) in the VRML plugin when current directory is not writable
Matthew Fernandez [Sat, 31 Oct 2020 16:28:24 +0000 (09:28 -0700)]
fix: fclose(NULL) in the VRML plugin when current directory is not writable

The VRML plugin writes PNG files of each node in the graph alongside the VRML
output that then references these files. If you give no output location (do not
pass `-o` to dot), the VRML output is written to stdout and the node PNG files
are written to the current directory. However, the plugin was not checking
whether opening of these PNG files succeeded. As a result, if the current
directory was not writable, it would end up calling fclose() with a NULL
pointer.

This change makes the plugin report the failure to open PNG files and cause dot
to eventually exit with non-zero. Note that VRML processing is not stopped, so
the user can still get complete VRML output, albeit missing the associated PNG
files that will be referenced.

The test case included in this commit does not necessarily reproduce the failure
prior to these changes. This is because Glibc allows fclose(NULL). However, this
is beyond the spec and other libcs do not provide these guarantees.

Fixes #793.

4 years agoMerge branch 'smattr/8b5fbbeb-e221-4eb3-a26b-0935708c3521' into 'master'
Matthew Fernandez [Wed, 4 Nov 2020 16:27:20 +0000 (16:27 +0000)]
Merge branch 'smattr/8b5fbbeb-e221-4eb3-a26b-0935708c3521' into 'master'

remove unnecessary branching for malloc/realloc

See merge request graphviz/graphviz!1652

4 years agoremove unnecessary cast of a parameter to realloc()
Matthew Fernandez [Thu, 29 Oct 2020 02:54:31 +0000 (19:54 -0700)]
remove unnecessary cast of a parameter to realloc()

This implicitly coerces to void*.

4 years agoremove some unnecessary allocation casts
Matthew Fernandez [Thu, 29 Oct 2020 02:51:47 +0000 (19:51 -0700)]
remove some unnecessary allocation casts

These return values implicitly coerce to other pointer types.

4 years agoremove some unnecessary branching for malloc/realloc
Matthew Fernandez [Thu, 29 Oct 2020 02:50:49 +0000 (19:50 -0700)]
remove some unnecessary branching for malloc/realloc

When realloc() is passed NULL as its first parameter, it acts the same as
malloc().

4 years agoremove some commented out code
Matthew Fernandez [Thu, 29 Oct 2020 02:48:51 +0000 (19:48 -0700)]
remove some commented out code

4 years agoMerge branch 'smattr/5d4e3a2b-8dff-4eee-81b1-76ad3a6885be' into 'master'
Matthew Fernandez [Wed, 4 Nov 2020 15:57:52 +0000 (15:57 +0000)]
Merge branch 'smattr/5d4e3a2b-8dff-4eee-81b1-76ad3a6885be' into 'master'

squash some compiler warnings

See merge request graphviz/graphviz!1651

4 years agosquash a -Wconversion warning
Matthew Fernandez [Thu, 29 Oct 2020 01:19:31 +0000 (18:19 -0700)]
squash a -Wconversion warning

4 years agosquash a -Wconversion warning
Matthew Fernandez [Thu, 29 Oct 2020 01:19:17 +0000 (18:19 -0700)]
squash a -Wconversion warning

4 years agosquash some -Wconversion warnings
Matthew Fernandez [Thu, 29 Oct 2020 01:18:57 +0000 (18:18 -0700)]
squash some -Wconversion warnings

4 years agoremove an unnecessary cast
Matthew Fernandez [Thu, 29 Oct 2020 01:18:31 +0000 (18:18 -0700)]
remove an unnecessary cast

Squashes a -Wcast-qual warning.

4 years agoremove unused addSpace parameter to gv_trim_zeros()
Matthew Fernandez [Thu, 29 Oct 2020 01:08:42 +0000 (18:08 -0700)]
remove unused addSpace parameter to gv_trim_zeros()

4 years agoMerge branch 'smattr/DF679B9B-496A-45B6-B14B-856D8DD8212B' into 'master'
Matthew Fernandez [Tue, 3 Nov 2020 01:36:44 +0000 (01:36 +0000)]
Merge branch 'smattr/DF679B9B-496A-45B6-B14B-856D8DD8212B' into 'master'

make compiler warnings for CMake Linux/macOS builds fail CI

See merge request graphviz/graphviz!1653

4 years agoMerge branch 'with-quartz-yes-on-macos' into 'master'
Magnus Jacobsson [Sun, 1 Nov 2020 14:05:47 +0000 (14:05 +0000)]
Merge branch 'with-quartz-yes-on-macos' into 'master'

Enable building with quartz on macOS

See merge request graphviz/graphviz!1649

4 years agoAdd --with-quartz=yes to configure on macOS
Magnus Jacobsson [Mon, 26 Oct 2020 07:20:39 +0000 (08:20 +0100)]
Add --with-quartz=yes to configure on macOS

4 years agoMerge branch 'smattr/4EEAF0CE-D0C3-479C-A9F1-A91B90168C2F' into 'master'
Matthew Fernandez [Sun, 1 Nov 2020 03:20:08 +0000 (03:20 +0000)]
Merge branch 'smattr/4EEAF0CE-D0C3-479C-A9F1-A91B90168C2F' into 'master'

fix some #includes in the Quartz plugin

See merge request graphviz/graphviz!1648

4 years agofix some #includes in the Quartz plugin
Matthew Fernandez [Sun, 25 Oct 2020 20:50:46 +0000 (13:50 -0700)]
fix some #includes in the Quartz plugin

This reverts part of d80f685dbacc2cfa3e496415739b4d6cfad32233 that incorrectly
updated paths to the header gvplugin_quartz.h. This mistake was not detected at
the time as we did not have macOS CI. Thanks to Stephen for picking this up.
Related to #1785.

4 years agomake compiler warnings for CMake Linux/macOS builds fail CI smattr/DF679B9B-496A-45B6-B14B-856D8DD8212B
Matthew Fernandez [Sat, 31 Oct 2020 03:20:41 +0000 (20:20 -0700)]
make compiler warnings for CMake Linux/macOS builds fail CI

Now that these builds are warning-free, we can "turn the ratchet" to demand they
stay warning-free or constitute a regression.

4 years agoMerge branch 'smattr/9f1ba4b1-6f37-4d49-b1a2-3f1fee7ee743' into 'master'
Matthew Fernandez [Sat, 31 Oct 2020 02:40:03 +0000 (02:40 +0000)]
Merge branch 'smattr/9f1ba4b1-6f37-4d49-b1a2-3f1fee7ee743' into 'master'

some pythonizing of rtest

See merge request graphviz/graphviz!1646

4 years agouse write() instead of print() for writing to a file
Matthew Fernandez [Sat, 24 Oct 2020 19:49:20 +0000 (12:49 -0700)]
use write() instead of print() for writing to a file

4 years agoremove unused GRAPH variable
Matthew Fernandez [Sat, 24 Oct 2020 19:43:38 +0000 (12:43 -0700)]
remove unused GRAPH variable

4 years agoremove unused IDX variable
Matthew Fernandez [Sat, 24 Oct 2020 19:42:45 +0000 (12:42 -0700)]
remove unused IDX variable

4 years agounfuse another with block in rtest
Matthew Fernandez [Sat, 24 Oct 2020 19:41:39 +0000 (12:41 -0700)]
unfuse another with block in rtest

4 years agounfuse a with block in rtest
Matthew Fernandez [Sat, 24 Oct 2020 19:40:03 +0000 (12:40 -0700)]
unfuse a with block in rtest

4 years agofix handling of KFLAGS and TFLAGS in rtest
Matthew Fernandez [Sat, 24 Oct 2020 19:32:12 +0000 (12:32 -0700)]
fix handling of KFLAGS and TFLAGS in rtest

This was potentially appending empty strings to the command passed to
subprocess.

4 years agowrite readSubtests() more Pythonically
Matthew Fernandez [Sat, 24 Oct 2020 19:20:04 +0000 (12:20 -0700)]
write readSubtests() more Pythonically

4 years agouse shutil.rmtree in preference to pathlib unlink
Matthew Fernandez [Sat, 24 Oct 2020 19:15:10 +0000 (12:15 -0700)]
use shutil.rmtree in preference to pathlib unlink

The missing_ok argument was only added to pathlib.Path.unlink in Python 3.8.
This made the cleanup function fail (sometimes silently) on versions of Python
prior to 3.8.

4 years agofix: remove unused format arguments in rtest
Matthew Fernandez [Sat, 24 Oct 2020 18:58:12 +0000 (11:58 -0700)]
fix: remove unused format arguments in rtest

This was detected by `python3 -m pylint --errors-only rtest/rtest.py`.

4 years agoMerge branch 'smattr/81334456-1889-4c1c-b6ee-3e83aa779c2f' into 'master'
Matthew Fernandez [Sat, 31 Oct 2020 02:09:33 +0000 (02:09 +0000)]
Merge branch 'smattr/81334456-1889-4c1c-b6ee-3e83aa779c2f' into 'master'

fix macOS CMake build warnings

See merge request graphviz/graphviz!1644

4 years agofix printf format code in agnameof()
Matthew Fernandez [Sat, 24 Oct 2020 17:28:38 +0000 (10:28 -0700)]
fix printf format code in agnameof()

This fixes a build warning on macOS when using CMake. Related to !1620.

4 years agouse safer snprintf in agnameof()
Matthew Fernandez [Sat, 24 Oct 2020 17:24:34 +0000 (10:24 -0700)]
use safer snprintf in agnameof()

4 years agoreduce the scope of a buffer in agnameof()
Matthew Fernandez [Sat, 24 Oct 2020 17:24:11 +0000 (10:24 -0700)]
reduce the scope of a buffer in agnameof()

4 years agofix printf format code in write_nodename()
Matthew Fernandez [Sat, 24 Oct 2020 17:22:35 +0000 (10:22 -0700)]
fix printf format code in write_nodename()

This fixes a build warning on macOS when using CMake. Related to !1620.

4 years agouse safer snprintf in write_nodename()
Matthew Fernandez [Sat, 24 Oct 2020 17:13:39 +0000 (10:13 -0700)]
use safer snprintf in write_nodename()

4 years agoreduce the scope of buffer in write_nodename()
Matthew Fernandez [Sat, 24 Oct 2020 17:13:04 +0000 (10:13 -0700)]
reduce the scope of buffer in write_nodename()

4 years agofix buffer overflow in write_nodename()
Matthew Fernandez [Sat, 24 Oct 2020 17:11:36 +0000 (10:11 -0700)]
fix buffer overflow in write_nodename()

This buffer was not large enough to print the string and uint64_t that gets
written into it. Related to !1620.

4 years agofix missing bracketing in a macro expansion
Matthew Fernandez [Sat, 24 Oct 2020 16:53:57 +0000 (09:53 -0700)]
fix missing bracketing in a macro expansion

None of the calls to this macro were passing in multiple tokens, so this issue
was latent. This refactor is for the safety of any future introduced calls to
EMPTY().

4 years agofix handling of varargs in gvprintf
Matthew Fernandez [Sat, 24 Oct 2020 16:43:24 +0000 (09:43 -0700)]
fix handling of varargs in gvprintf

It is not safe to re-va_start a va_list the way this code was previously
operating. This probably worked by coincidence on platforms like x86-64.

4 years agoswitch to safer snprintf in portName()
Matthew Fernandez [Sat, 24 Oct 2020 16:49:36 +0000 (09:49 -0700)]
switch to safer snprintf in portName()

4 years agofix print of an AGSEQ
Matthew Fernandez [Sat, 24 Oct 2020 16:24:33 +0000 (09:24 -0700)]
fix print of an AGSEQ

This squashes a build warning on macOS when using CMake. Related to !1620.

4 years agofix a buffer overflow in string construction
Matthew Fernandez [Sat, 24 Oct 2020 16:17:54 +0000 (09:17 -0700)]
fix a buffer overflow in string construction

The conditional in this code was the wrong way around. So the %s branch could be
taken only when the resulting sprintf would *definitely* overflow the target
buffer. From this we can conclude this branch was never safe and never used
correctly. For simplicity, we remove it, leaving only the %d option. Related to
!1620.

4 years agoMerge branch 'smattr/029D9712-951E-4082-B254-9B0BB83BC384' into 'master'
Matthew Fernandez [Sat, 31 Oct 2020 00:21:17 +0000 (00:21 +0000)]
Merge branch 'smattr/029D9712-951E-4082-B254-9B0BB83BC384' into 'master'

remove a use of setjmp/longjmp

See merge request graphviz/graphviz!1645

4 years agoremove a now unused jmp_buf
Matthew Fernandez [Sat, 24 Oct 2020 18:51:27 +0000 (11:51 -0700)]
remove a now unused jmp_buf

Related to #1801.

4 years agoindicate failure in growops() by return value instead of longjmp()
Matthew Fernandez [Sat, 24 Oct 2020 18:50:47 +0000 (11:50 -0700)]
indicate failure in growops() by return value instead of longjmp()

Related to #1801.

4 years agoindicate failure from growtris() by return value instead of longjmp()
Matthew Fernandez [Sat, 24 Oct 2020 18:44:39 +0000 (11:44 -0700)]
indicate failure from growtris() by return value instead of longjmp()

Related to #1801.

4 years agoadd a return value to loadtriangle()
Matthew Fernandez [Sat, 24 Oct 2020 18:39:19 +0000 (11:39 -0700)]
add a return value to loadtriangle()

Related to #1801.

4 years agoadd a return value to triangulate()
Matthew Fernandez [Sat, 24 Oct 2020 18:33:34 +0000 (11:33 -0700)]
add a return value to triangulate()

Related to #1801.

4 years agoremove unnecessary use of longjmp() in growdq()
Matthew Fernandez [Sat, 24 Oct 2020 18:23:56 +0000 (11:23 -0700)]
remove unnecessary use of longjmp() in growdq()

Related to #1801.

4 years agoremove an unnecessary use of longjmp() in growpnls()
Matthew Fernandez [Sat, 24 Oct 2020 18:17:54 +0000 (11:17 -0700)]
remove an unnecessary use of longjmp() in growpnls()

Related to #1801.

4 years agoMerge branch 'smattr/4b7c9c53-bdf9-48ef-8fa6-7c06fc5720b4' into 'master'
Matthew Fernandez [Fri, 30 Oct 2020 14:08:00 +0000 (14:08 +0000)]
Merge branch 'smattr/4b7c9c53-bdf9-48ef-8fa6-7c06fc5720b4' into 'master'

stop shipping strcasecmp.h

See merge request graphviz/graphviz!1642

4 years agostop shipping strcasecmp.h
Matthew Fernandez [Sat, 24 Oct 2020 03:02:07 +0000 (20:02 -0700)]
stop shipping strcasecmp.h

The header strcasecmp.h is a portability shim that was introduced in
cadb72d6157603338a990be4e27a599c7b96b214. However, no installed Graphviz headers
#include this header, so we do not need to install it. It is cleaner not to
clutter the shipped Graphviz include directory with an internal shim like this.

Note that there is no changelog entry for this change and this is not an API
break because there has not yet been a release since this header was added.

4 years agoMerge branch 'orientation' into 'master'
Mark Hansen [Thu, 29 Oct 2020 10:01:43 +0000 (10:01 +0000)]
Merge branch 'orientation' into 'master'

Delete attrs.html from main graphviz repo

Closes graphviz.gitlab.io#65

See merge request graphviz/graphviz!1641

4 years agoDelete attrs.html from main graphviz repo
Mark Hansen [Thu, 29 Oct 2020 09:32:45 +0000 (20:32 +1100)]
Delete attrs.html from main graphviz repo

This now canonically lives in the graphviz.gitlab.io repo (the docs repo):

https://gitlab.com/graphviz/graphviz.gitlab.io/-/blob/master/doc/info/attrs.html

This gives one central source of truth for the docs, so that people
updating the docs don't have to update 3 locations (doc/info,
doc/infosrc, and the docs repo).

It's perhaps a little controversial to redirect the old docs. The old
docs are still built into some OS's HTML docs packages, but I imagine
the vast majority of users access docs through the graphviz website
after using a search engine to find them.

Fixes https://gitlab.com/graphviz/graphviz.gitlab.io/-/issues/65

4 years agoMerge branch 'smattr/f037c2f4-a5af-4f90-a41d-412fb74c4296' into 'master'
Matthew Fernandez [Thu, 29 Oct 2020 01:19:47 +0000 (01:19 +0000)]
Merge branch 'smattr/f037c2f4-a5af-4f90-a41d-412fb74c4296' into 'master'

add CI testing of HTML files in the repository

See merge request graphviz/graphviz!1637

4 years agorun pytest with --verbose in CI
Matthew Fernandez [Fri, 23 Oct 2020 00:02:57 +0000 (17:02 -0700)]
run pytest with --verbose in CI

This makes it a little easier to see from the logs which tests were skipped and
to validate that the tests you think are being found are actually running.

4 years agoadd test cases for validating in-repo HTML files
Matthew Fernandez [Fri, 23 Oct 2020 00:00:37 +0000 (17:00 -0700)]
add test cases for validating in-repo HTML files

Related to #1861.

4 years agoMerge branch 'smattr/38BA03F9-7DC4-4E4F-8B4C-51C3F360855D' into 'master'
Matthew Fernandez [Thu, 29 Oct 2020 00:49:13 +0000 (00:49 +0000)]
Merge branch 'smattr/38BA03F9-7DC4-4E4F-8B4C-51C3F360855D' into 'master'

remove unnecessary casts and fix a memory leak

See merge request graphviz/graphviz!1630

4 years agoremove unnecessary casts from parameters to memcpy
Matthew Fernandez [Thu, 22 Oct 2020 00:05:05 +0000 (17:05 -0700)]
remove unnecessary casts from parameters to memcpy

These implicitly coerce to void* so a cast is not required.

4 years agorephrase some swapping code
Matthew Fernandez [Thu, 22 Oct 2020 00:05:01 +0000 (17:05 -0700)]
rephrase some swapping code

C allows you to assign structs in this way, so there's no need to use a more
confusing memcpy sequence.

4 years agoremove unnecessary casts on arguments to free()
Matthew Fernandez [Thu, 22 Oct 2020 00:04:53 +0000 (17:04 -0700)]
remove unnecessary casts on arguments to free()

These implicitly coerce to void* so no cast is needed.

4 years agoremove unnecessary guards on calls to free()
Matthew Fernandez [Thu, 22 Oct 2020 00:04:48 +0000 (17:04 -0700)]
remove unnecessary guards on calls to free()

Freeing NULL is a no-op, so there is no need for these extra conditionals.

4 years agofix memory leak in gvplugin_list
Matthew Fernandez [Thu, 22 Oct 2020 00:04:44 +0000 (17:04 -0700)]
fix memory leak in gvplugin_list

It seems clear these conditionals were reversed and were meant to read
`if (typestr_list)`. Rather than flip their polarity, we just remove them as it
is safe to free NULL.