1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2025-10-24 12:07:40 +00:00

Fix wrong order of arguments in calloc

This commit is contained in:
Carles Fernandez
2024-04-22 09:48:28 +02:00
parent c6010d943e
commit c91c31bd35

View File

@@ -1034,7 +1034,7 @@ double *zeros(int n, int m)
{
return nullptr;
}
if (!(p = static_cast<double *>(calloc(sizeof(double), n * m))))
if (!(p = static_cast<double *>(calloc(n * m, sizeof(double)))))
{
fatalerr("matrix memory allocation error: n=%d,m=%d\n", n, m);
}