diff options
author | Wesley Shields <wxs@FreeBSD.org> | 2010-01-30 15:30:13 +0000 |
---|---|---|
committer | Wesley Shields <wxs@FreeBSD.org> | 2010-01-30 15:30:13 +0000 |
commit | fc3f47f07f4be045007b673deb34c5ba98ac6b9e (patch) | |
tree | 0e99a47052ed9ceadd43b54f386be6f052a0fd91 /graphics | |
parent | 8a0e20bfcd0fcee4f3dfafaf19bef02710b78e12 (diff) | |
download | ports-fc3f47f07f4be045007b673deb34c5ba98ac6b9e.tar.gz ports-fc3f47f07f4be045007b673deb34c5ba98ac6b9e.zip |
Notes
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/plotutils/files/patch-libplot-x_afftext.c | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/graphics/plotutils/files/patch-libplot-x_afftext.c b/graphics/plotutils/files/patch-libplot-x_afftext.c new file mode 100644 index 000000000000..88cc516becc5 --- /dev/null +++ b/graphics/plotutils/files/patch-libplot-x_afftext.c @@ -0,0 +1,46 @@ +--- libplot/x_afftext.c.orig 2010-01-25 01:37:45.000000000 -0500 ++++ libplot/x_afftext.c 2010-01-25 01:38:02.000000000 -0500 +@@ -185,7 +185,10 @@ + /* invert transformation matrix */ + det = aa[0] * aa[3] - aa[1] * aa[2]; + if (det == 0.0) ++ { ++ free(afftext); + return NULL; /* don't support singular matrices */ ++ } + a_inverse[0] = aa[3] / det; + a_inverse[1] = - aa[1] / det; + a_inverse[2] = - aa[2] / det; +@@ -205,7 +208,10 @@ + + /* paranoia */ + if (size_in.x == 0 || size_in.y == 0) ++ { ++ free(afftext); + return NULL; ++ } + + /* work around a possible bug: some X displays can't create pixmaps that + are only one pixel wide or high */ +@@ -238,7 +244,10 @@ + /* create local image */ + im_in = XAffCreateXImage (dpy, size_in); + if (im_in == NULL) ++ { ++ free(afftext); + return NULL; ++ } + + /* copy bitmap to it */ + XGetSubImage (dpy, bitmap_in, 0, 0, size_in.x, size_in.y, +@@ -308,7 +317,10 @@ + /* create 2nd image, to hold affinely transformed text */ + im_out = XAffCreateXImage (dpy, size_out); + if (im_out == NULL) ++ { ++ free(afftext); + return NULL; ++ } + + /* copy from 1st image to this new one */ + |