]> granicus.if.org Git - graphviz/commit
get_triangles: fix mismatch of calling convention in 'addTri'
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 7 Nov 2021 20:07:00 +0000 (12:07 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Wed, 10 Nov 2021 02:34:09 +0000 (18:34 -0800)
commitc7a4f90197656e7492fda8e2e0016925feb562aa
tree26ecf48a38d8261f18daf28856efe37b385f8579
parentcbcd11bb087dc19b3d3d4d208e395f3b934cb1c6
get_triangles: fix mismatch of calling convention in 'addTri'

The compiler said about this code:

  delaunay.c:518:34: warning: cast between incompatible function types from
    ‘void (*)(GFace *, fstate *)’ {aka ‘void (*)(struct <anonymous> *, struct
    <anonymous> *)’} to ‘gint (*)(void *, void *)’ {aka
    ‘int (*)(void *, void *)’} [-Wcast-function-type]
       gts_surface_foreach_face (s, (GtsFunc) addTri, &statf);
                                    ^

Similar to the prior commit, this was relying on a coincident return value of 0
from the callback function.
lib/neatogen/delaunay.c