From 259f4c36d581896ce605741b9e557a589013a9b8 Mon Sep 17 00:00:00 2001 From: Daniel Stone Date: Mon, 5 Nov 2007 14:09:49 +0000 Subject: [PATCH] Xprint: Remove usage of alloca Replace with heap-based allocations. --- hw/xprint/ps/PsText.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/xprint/ps/PsText.c b/hw/xprint/ps/PsText.c index 98cf15345..872c0f427 100644 --- a/hw/xprint/ps/PsText.c +++ b/hw/xprint/ps/PsText.c @@ -535,7 +535,7 @@ PsPolyGlyphBlt( nbyLine = BitmapBytePad(width); - pbits = (unsigned char *)ALLOCATE_LOCAL(height*nbyLine); + pbits = (unsigned char *)xalloc(height*nbyLine); if (!pbits){ PsDestroyPixmap(pPixmap); return; @@ -576,6 +576,6 @@ PsPolyGlyphBlt( x += pci->metrics.characterWidth; } - DEALLOCATE_LOCAL(pbits); + xfree(pbits); FreeScratchGC(pGCtmp); }