diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2012-12-05 04:36:00 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2012-12-05 04:36:00 +0000 |
commit | 823be2c11c870129aac78e7c9a62b83b8d9a3f33 (patch) | |
tree | 89e50aedd78b95e38eaa221ab2161c6a914dbfb6 /generator/ppmpat.c | |
parent | 896a26371189fe2a394f9b0a1fc9c6e684b56c19 (diff) | |
download | netpbm-mirror-823be2c11c870129aac78e7c9a62b83b8d9a3f33.tar.gz netpbm-mirror-823be2c11c870129aac78e7c9a62b83b8d9a3f33.tar.xz netpbm-mirror-823be2c11c870129aac78e7c9a62b83b8d9a3f33.zip |
Fix integer promotion mess
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@1801 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'generator/ppmpat.c')
-rw-r--r-- | generator/ppmpat.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/generator/ppmpat.c b/generator/ppmpat.c index 100b4978..2e8092b3 100644 --- a/generator/ppmpat.c +++ b/generator/ppmpat.c @@ -843,8 +843,8 @@ poles(pixel ** const pixels, dist1 = dist2 = (SQR((double)cols) + SQR((double)rows)); for (i = 0; i < poleCt; ++i) { double const newdist = - (double)(col - xs[i]) * (col - xs[i]) + - (double)(row - ys[i]) * (row - ys[i]); + (double)((int)col - xs[i]) * ((int)col - xs[i]) + + (double)((int)row - ys[i]) * ((int)row - ys[i]); if (newdist < dist1) { dist2 = dist1; color2 = color1; |