pca: use av_calloc()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2013-04-15 20:27:06 +02:00
parent 003d497d31
commit 8a11114a79

View File

@ -44,8 +44,8 @@ PCA *ff_pca_init(int n){
pca->n= n;
pca->z = av_malloc(sizeof(*pca->z) * n);
pca->count=0;
pca->covariance= av_mallocz(sizeof(double)*n*n);
pca->mean= av_mallocz(sizeof(double)*n);
pca->covariance= av_calloc(n*n, sizeof(double));
pca->mean= av_calloc(n, sizeof(double));
return pca;
}