[gimp/gimp-2-10] plug-ins: fix some build warning.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gimp-2-10] plug-ins: fix some build warning.
- Date: Sun, 19 Apr 2020 10:58:50 +0000 (UTC)
commit aaa55f90420196d5ec706d51139a5d129c8cad0c
Author: Jehan <jehan girinstud io>
Date: Mon Apr 13 21:54:09 2020 +0200
plug-ins: fix some build warning.
Fixes:
> warning: using integer absolute value function ‘abs’ when argument is of floating point type ‘double’
[-Wabsolute-value]
(cherry picked from commit b71754f2a7c32f9ada99731a2e8334a98dcf6e73)
plug-ins/common/curve-bend.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/plug-ins/common/curve-bend.c b/plug-ins/common/curve-bend.c
index d578c37a16..dfa9ff7089 100644
--- a/plug-ins/common/curve-bend.c
+++ b/plug-ins/common/curve-bend.c
@@ -2248,9 +2248,9 @@ bender_graph_events (GtkWidget *widget,
for (i = 0; i < 17; i++)
{
if (cd->points[cd->outline][i][0] != -1)
- if (abs (x - (cd->points[cd->outline][i][0] * 255.0)) < distance)
+ if (abs ((int) (x - (cd->points[cd->outline][i][0] * 255.0))) < distance)
{
- distance = abs (x - (cd->points[cd->outline][i][0] * 255.0));
+ distance = abs ((int) (x - (cd->points[cd->outline][i][0] * 255.0)));
closest_point = i;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]