Files
graphviz/gvc-detect-plugin-installation-failure-and-display-an-error.patch
Thomas Renninger 736833a325 Accepting request 1281692 from home:alarrosa:branches:graphics
- Update to 12.2.1
  * Added
    - Support for building the SWIG-generated R language bindings
      has been integrated into the CMake build system. This is
      controllable by the -DENABLE_R={AUTO|ON|OFF} option.
    - A sandboxing wrapper, dot_sandbox, is now included with
      Graphviz. Users should prefer their platform’s native
      security solutions, but if nothing better is available this
      wrapper offers safe processing of untrusted inputs in some
      scenarios.
  * Changed
    - JPEG images without an APP0 leading segment are supported for
      use in src fields and friends. Previously Graphviz was overly
      strict with the types of JPEGs it would recognize. #2619
    - The CMake build system now discovers and uses
      pango_fc_font_lock_face if possible, for the Pango plugin to
      provide more information about used fonts.
  * Fixed
    - The GVPR library program depath no longer acts on previously
      deleted nodes, causing unpredictable results. #1702 (closed)
    - Void-typed function parameters (int foo(void bar)) and
      variables void baz; in GVPR are gracefully rejected.
      #2585 (closed)
    - Input that induce a set node height but no set node width no
      longer crash with the failure "Assertion failed:
      (r->boundary[i] <= r->boundary[NUMDIMS + i]), function
      RTreeInsert". It is typically not obvious to users when their
      input falls into this situation, hence why the assertion
      message is quoted here. This was a regression in Graphviz
      12.0.0. #2613 (closed)

OBS-URL: https://build.opensuse.org/request/show/1281692
OBS-URL: https://build.opensuse.org/package/show/graphics/graphviz?expand=0&rev=199
2025-06-04 18:00:50 +00:00

32 lines
1.0 KiB
Diff

From: Matthew Fernandez <matthew.fernandez@gmail.com>
Subject: gvc: detect plugin installation failure and display an error
References: bsc#1219491
Patch-Mainline: 10.0.1
Git-commit: a95f977f5d809915ec4b14836d2b5b7f5e74881e
Git-repo: git@gitlab.com:graphviz/graphviz.git.git
Gitlab: fixes #2441
Reported-by: GJDuck
A malformed config6 file that leads to plugin search failing no longer causes
out-of-bounds memory reads. This now causes an error message and graceful
failure. #2441
Signed-off-by: <trenn@suse.com>
Index: graphviz-2.49.3/lib/gvc/gvconfig.c
===================================================================
--- graphviz-2.49.3.orig/lib/gvc/gvconfig.c
+++ graphviz-2.49.3/lib/gvc/gvconfig.c
@@ -183,6 +183,10 @@ static int gvconfig_plugin_install_from_
do {
api = token(&nest, &s);
gv_api = gvplugin_api(api);
+ if (gv_api == (api_t)-1) {
+ agerr(AGERR, "config error: %s %s not found\n", path, api);
+ return 0;
+ }
do {
if (nest == 2) {
type = token(&nest, &s);