summaryrefslogtreecommitdiff
path: root/mi/mizerline.c
diff options
context:
space:
mode:
authorDaniel Stone <daniel@fooishbar.org>2007-11-05 14:08:51 +0000
committerDaniel Stone <daniel@fooishbar.org>2007-11-05 14:34:41 +0000
commitbe9ee17f960cc3d8a8f999cab1579e83d9aea520 (patch)
treef563ce4405d197063ed262da3f5355d334335e43 /mi/mizerline.c
parent3633ae6efb57c5405c26e8ae132b9371e5f920de (diff)
mi: Remove usage of alloca
Replace with heap allocations.
Diffstat (limited to 'mi/mizerline.c')
-rw-r--r--mi/mizerline.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/mi/mizerline.c b/mi/mizerline.c
index 073f1b20f..6604a0923 100644
--- a/mi/mizerline.c
+++ b/mi/mizerline.c
@@ -155,8 +155,8 @@ miZeroLine(pDraw, pGC, mode, npt, pptInit)
width = xright - xleft + 1;
height = ybottom - ytop + 1;
list_len = (height >= width) ? height : width;
- pspanInit = (DDXPointPtr)ALLOCATE_LOCAL(list_len * sizeof(DDXPointRec));
- pwidthInit = (int *)ALLOCATE_LOCAL(list_len * sizeof(int));
+ pspanInit = (DDXPointPtr)xalloc(list_len * sizeof(DDXPointRec));
+ pwidthInit = (int *)xalloc(list_len * sizeof(int));
if (!pspanInit || !pwidthInit)
return;
@@ -359,8 +359,8 @@ miZeroLine(pDraw, pGC, mode, npt, pptInit)
(*pGC->ops->FillSpans)(pDraw, pGC, Nspans, pspanInit,
pwidthInit, FALSE);
- DEALLOCATE_LOCAL(pwidthInit);
- DEALLOCATE_LOCAL(pspanInit);
+ xfree(pwidthInit);
+ xfree(pspanInit);
}
_X_EXPORT void