summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qgrayraster.c
diff options
context:
space:
mode:
authorHarald Fernengel <harald@trolltech.com>2009-08-03 15:12:46 +0200
committerHarald Fernengel <harald@trolltech.com>2009-08-03 15:12:46 +0200
commit41a83e1ff19ad1396e6001e6b0ac003c701ba55a (patch)
tree609e40eda10418bbf925002c36552074796b96b6 /src/gui/painting/qgrayraster.c
parentd1f3b9df2bc5c57d414da73a7d4f9ed7b25df3db (diff)
Squashed commit of the topic/exceptions branch.
Contains some smaller fixes and renaming of macros. Looks big, but isn't scary at all ;)
Diffstat (limited to 'src/gui/painting/qgrayraster.c')
-rw-r--r--src/gui/painting/qgrayraster.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gui/painting/qgrayraster.c b/src/gui/painting/qgrayraster.c
index 888fd9adb0..f908d4803d 100644
--- a/src/gui/painting/qgrayraster.c
+++ b/src/gui/painting/qgrayraster.c
@@ -1880,6 +1880,10 @@
if (memory)
fprintf(stderr, "gray_raster_new(), memory ignored");
memory = malloc(sizeof(TRaster));
+ if (!memory) {
+ *araster = 0;
+ return ErrRaster_Memory_Overflow;
+ }
QT_FT_MEM_ZERO(memory, sizeof(TRaster));
*araster = (QT_FT_Raster) memory;