Skip to content

Commit 0849a62

Browse files
committed
Fix abs(long) warnings in gd.c
I'm fixing this using (int) casts instead of labs() because this is what upstream GD does.
1 parent fc65da5 commit 0849a62

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/gd/libgd/gd.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1256,7 +1256,7 @@ void gdImageAALine (gdImagePtr im, int x1, int y1, int x2, int y2, int col)
12561256
if (dx == 0 && dy == 0) {
12571257
return;
12581258
}
1259-
if (abs(dx) > abs(dy)) {
1259+
if (abs((int)dx) > abs((int)dy)) {
12601260
if (dx < 0) {
12611261
tmp = x1;
12621262
x1 = x2;

0 commit comments

Comments
 (0)