diff options
author | akupries@shaw.ca <andreas_kupries> | 2007-07-04 17:32:39 (GMT) |
---|---|---|
committer | akupries@shaw.ca <andreas_kupries> | 2007-07-04 17:32:39 (GMT) |
commit | 3b00bda12ced673b5b6be979da9c3f0a70ddc475 (patch) | |
tree | 636059a9196b912757a7c34c28c925dc2c4197d2 | |
parent | 15746427f1a4ee724e3df1944cd54ccf9a85190f (diff) | |
download | tk-3b00bda12ced673b5b6be979da9c3f0a70ddc475.zip tk-3b00bda12ced673b5b6be979da9c3f0a70ddc475.tar.gz tk-3b00bda12ced673b5b6be979da9c3f0a70ddc475.tar.bz2 |
* macosx/tkMacOSXXStubs.c (DestroyImage): Fixed seg.fault in
release of image data for images coming from XGetImage. Change
committed by me for Daniel Steffen. See 2007-06-23 for the
change which introduced the problem.
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | macosx/tkMacOSXXStubs.c | 5 |
2 files changed, 9 insertions, 3 deletions
@@ -1,3 +1,10 @@ +2007-07-04 Andreas Kupries <andreask@activestate.com> + + * macosx/tkMacOSXXStubs.c (DestroyImage): Fixed seg.fault in + release of image data for images coming from XGetImage. Change + committed by me for Daniel Steffen. See 2007-06-23 for the + change which introduced the problem. + 2007-07-02 Daniel Steffen <das@users.sourceforge.net> * xlib/xgc.c (XCreateGC): correct black and white pixel values used to diff --git a/macosx/tkMacOSXXStubs.c b/macosx/tkMacOSXXStubs.c index 6b2b7dd..31ae7ea 100644 --- a/macosx/tkMacOSXXStubs.c +++ b/macosx/tkMacOSXXStubs.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkMacOSXXStubs.c,v 1.22 2007/06/29 03:20:02 das Exp $ + * RCS: @(#) $Id: tkMacOSXXStubs.c,v 1.23 2007/07/04 17:32:39 andreas_kupries Exp $ */ #include "tkMacOSXPrivate.h" @@ -940,8 +940,7 @@ DestroyImage( if (image) { if (image->obdata) { Tk_FreePixmap((Display*) gMacDisplay, (Pixmap) image->obdata); - } - if (image->data) { + } else if (image->data) { ckfree(image->data); } ckfree((char*) image); |