blob: 88766e40f3002af389e76b06543d53368824e768 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
diff -Naur duhdraw-2.8.13/ansi.c duhdraw-2.8.13.patched/ansi.c
--- duhdraw-2.8.13/ansi.c 2005-03-02 03:22:46.000000000 -0500
+++ duhdraw-2.8.13.patched/ansi.c 2025-02-20 04:20:49.445520477 -0500
@@ -502,7 +502,7 @@
pos = 0;
splos = 0;
- editbuffer = (unsigned int *) malloc(sizeof(unsigned int) * cols * EDIT_BUFFER_HEIGHT);
+ editbuffer = (unsigned int *) malloc(sizeof(unsigned int) * (unsigned int)cols * EDIT_BUFFER_HEIGHT);
if (NULL == editbuffer)
{
fprintf (stderr, "Could not allocate memory for buffer.\n");
|