diff options
author | rbuj <[email protected]> | 2022-02-09 12:26:35 +0100 |
---|---|---|
committer | mbkma <[email protected]> | 2022-07-22 08:48:41 +0200 |
commit | 160d754f2228e74daea5735c9fb6655e082de906 (patch) | |
tree | a91ae7eb2fd831f4f87c36b9bf021a5df1be7848 /test | |
parent | b90c1c21ded05281f5ed9dfbbaac764f918300f8 (diff) | |
download | caja-160d754f2228e74daea5735c9fb6655e082de906.tar.bz2 caja-160d754f2228e74daea5735c9fb6655e082de906.tar.xz |
Fix build warning -Wbad-function-cast
Diffstat (limited to 'test')
-rw-r--r-- | test/test-eel-pixbuf-scale.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/test-eel-pixbuf-scale.c b/test/test-eel-pixbuf-scale.c index 2aa10ecf..ee6d9181 100644 --- a/test/test-eel-pixbuf-scale.c +++ b/test/test-eel-pixbuf-scale.c @@ -11,6 +11,8 @@ main (int argc, char* argv[]) GdkPixbuf *pixbuf, *scaled; GError *error; gint64 t1, t2; + int width; + int height; test_init (&argc, &argv); @@ -27,9 +29,11 @@ main (int argc, char* argv[]) exit (1); } + width = gdk_pixbuf_get_width (pixbuf); + height = gdk_pixbuf_get_height (pixbuf); printf ("scale factors: %f, %f\n", - (double)gdk_pixbuf_get_width(pixbuf)/DEST_WIDTH, - (double)gdk_pixbuf_get_height(pixbuf)/DEST_HEIGHT); + ((double) width) / ((double) DEST_WIDTH), + ((double) height) / ((double) DEST_HEIGHT)); t1 = g_get_monotonic_time (); scaled = eel_gdk_pixbuf_scale_down (pixbuf, DEST_WIDTH, DEST_HEIGHT); |