diff options
author | wilson chen <willson.chenwx@gmail.com> | 2020-03-21 15:31:40 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-21 15:31:40 +0800 |
commit | 3f50ffaefdf8bf5ec5441afb4f032d32de8be7a4 (patch) | |
tree | d4c5bef5f21e24bd1cdc1257d02c82786518dde8 /src/gd_matrix.c | |
parent | 08238a0ac2a309d1009ccfcf53f7e9908ae61881 (diff) | |
download | libgd-3f50ffaefdf8bf5ec5441afb4f032d32de8be7a4.tar.gz |
Fixed #596: gdTransformAffineCopy run error
And add test case for it.
Diffstat (limited to 'src/gd_matrix.c')
-rw-r--r-- | src/gd_matrix.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gd_matrix.c b/src/gd_matrix.c index 7d3fe35..ada63e6 100644 --- a/src/gd_matrix.c +++ b/src/gd_matrix.c @@ -63,7 +63,7 @@ BGD_DECLARE(int) gdAffineInvert (double dst[6], const double src[6]) { double r_det = (src[0] * src[3] - src[1] * src[2]); - if (r_det <= 0.0) { + if (fabs(r_det) <= 0.0) { return GD_FALSE; } |