[FREETYPE] Handle allocation failures in our stack-saving hacks. CORE-15642
[reactos.git] / sdk / lib / 3rdparty / freetype / src / smooth / ftgrays.c
index e5fb3c7..a5ec55b 100644 (file)
@@ -1757,6 +1757,10 @@ typedef ptrdiff_t  FT_PtrDist;
 
 #ifdef __REACTOS__
     buffer = malloc(FT_MAX(FT_RENDER_POOL_SIZE, 2048));
+    if (!buffer)
+    {
+      return 1;
+    }
 #endif
 
     /* set up vertical bands */