polygon-intersection: Clarify ptr checks for right edges (CID #1160730)
commit2b6b23fd8cfae768145e9a9f1f27eb0415e2a617
authorBryce Harrington <bryce@bryceharrington.org>
Wed, 13 Jun 2018 00:18:58 +0000 (12 17:18 -0700)
committerBryce Harrington <bryce@bryceharrington.org>
Wed, 13 Jun 2018 22:21:50 +0000 (13 15:21 -0700)
treeeab4d96af29dd00f63a886ef43c6c423f17fa3e4
parent5a4a86c27f733645a2276d0a3bd2494e73b3dc88
polygon-intersection: Clarify ptr checks for right edges (CID #1160730)

The code is checking a variable is non-NULL after it's already been
dereferenced in an assert.

I'm not certain whether the assert should be conditionalized to only be
tested when right != NULL (which would allow edges_end() to still be
invoked), or if the function should assert right as non-NULL always.

Coverity ID: #1160730
Signed-off-by: Bryce Harrington <bryce@bryceharrington.org>
Reviewed-By: Uli Schlachter <psychon@znc.in>
src/cairo-polygon-intersect.c