From 79d51ce64560bab7b01aa67b7cbc3effb28c0964 Mon Sep 17 00:00:00 2001
From: Laurent <laurent.thomas@open-cells.com>
Date: Sat, 26 Dec 2020 11:05:42 +0100
Subject: [PATCH] reallocarray() doesn't exist in old Ubuntu

---
 common/utils/ocp_itti/intertask_interface.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/utils/ocp_itti/intertask_interface.cpp b/common/utils/ocp_itti/intertask_interface.cpp
index a1455577d32..aec702f9873 100644
--- a/common/utils/ocp_itti/intertask_interface.cpp
+++ b/common/utils/ocp_itti/intertask_interface.cpp
@@ -340,7 +340,7 @@ extern "C" {
     pthread_mutex_lock (&lock_nb_queues);
     int newQueue=nb_queues;
     nb_queues++;
-    AssertFatal(reallocarray(tasks, nb_queues, sizeof(*tasks)),"no memory");
+    AssertFatal(realloc(tasks, nb_queues* sizeof(*tasks)),"no memory");
     pthread_mutex_unlock (&lock_nb_queues);
     LOG_I(TMR,"Starting itti queue: %s as task %d\n", tasks_info->name, newQueue);
     pthread_mutex_init(&tasks[newQueue].queue_cond_lock, NULL);
-- 
GitLab