summaryrefslogtreecommitdiffstats
path: root/thread.c
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>2003-04-08 10:21:01 +0000
committerThomas Roessler <roessler@does-not-exist.org>2003-04-08 10:21:01 +0000
commit65931dfdd0d1a6eea3fc1d73b6e9a048152dfb65 (patch)
treea15c14070964bc5f07f74efdc5935e246cd4cd38 /thread.c
parentb0a640c11320cfcec97ec03cf7a1d07dee586d57 (diff)
Try to catch a couple of cases in which parameters for malloc calls
could overflow. Thanks to Timo Sirainen for the heads-up.
Diffstat (limited to 'thread.c')
-rw-r--r--thread.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/thread.c b/thread.c
index 0896c24f..bd45392f 100644
--- a/thread.c
+++ b/thread.c
@@ -591,7 +591,7 @@ THREAD *mutt_sort_subthreads (THREAD *thread, int init)
top = thread;
- array = safe_malloc ((array_size = 256) * sizeof (THREAD *));
+ array = safe_calloc ((array_size = 256), sizeof (THREAD *));
while (1)
{
if (init || !thread->sort_key)