]> granicus.if.org Git - graphviz/commitdiff
GD plugin: remove unnecessary casts
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Tue, 19 Jul 2022 02:59:46 +0000 (19:59 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Tue, 26 Jul 2022 02:01:28 +0000 (19:01 -0700)
plugin/gd/gvloadimage_gd.c

index 5afba5232381eb8d25506cbb2f7b72573fab0b13..8b0ce6506f178b98ce208e1190239cf8e096fc26 100644 (file)
@@ -90,7 +90,7 @@ static gdImagePtr gd_rotateimage(gdImagePtr im, int rotation)
        
 static void gd_loadimage_gd(GVJ_t * job, usershape_t *us, boxf b, bool filled)
 {
-    gdImagePtr im2, im = (gdImagePtr) job->context;
+    gdImagePtr im2, im = job->context;
 
     if ((im2 = gd_loadimage(job, us))) {
         if (job->rotation)
@@ -103,7 +103,7 @@ static void gd_loadimage_gd(GVJ_t * job, usershape_t *us, boxf b, bool filled)
 #ifdef HAVE_PANGOCAIRO
 static void gd_loadimage_cairo(GVJ_t * job, usershape_t *us, boxf b, bool filled)
 {
-    cairo_t *cr = (cairo_t *) job->context; /* target context */
+    cairo_t *cr = job->context; /* target context */
     unsigned int x, y, stride, width, height, px;
     unsigned char *data;
     cairo_surface_t *surface;    /* source surface */