History

avutil/pca: Use av_malloc_array()

Michael Niedermayer committed 12 years ago

Commit beecfa81 parent 35e16b11 file · +1 −1Browse files

Unified · Split

libavutil/pca.c+1−1
@@ -42,7 +42,7 @@ PCA *ff_pca_init(int n){ · 41 unmodified lines
4242
4343 pca= av_mallocz(sizeof(*pca));
4444 pca->n= n;
45− pca->z = av_malloc(sizeof(*pca->z) * n);
45+ pca->z = av_malloc_array(n, sizeof(*pca->z));
4646 pca->count=0;
4747 pca->covariance= av_calloc(n*n, sizeof(double));
4848 pca->mean= av_calloc(n, sizeof(double));

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t