diff options
| author | 2026-04-13 17:01:47 -0400 | |
|---|---|---|
| committer | 2026-04-13 17:01:47 -0400 | |
| commit | 77b54c35bf9587450cd636e0d7df37e190e28bfb (patch) | |
| tree | a290efdd8b09066847199f3f52a32be70d24ef51 /src/codec/common.h | |
| parent | 20617b9c80cf8d8051ecdb53a2c22f68c012f21b (diff) | |
| download | camu-77b54c35bf9587450cd636e0d7df37e190e28bfb.tar.gz camu-77b54c35bf9587450cd636e0d7df37e190e28bfb.tar.bz2 camu-77b54c35bf9587450cd636e0d7df37e190e28bfb.zip | |
Smaller stuff that went uncommitted
Signed-off-by: Andrew Opalach <andrew@akon.city>
Diffstat (limited to 'src/codec/common.h')
| -rw-r--r-- | src/codec/common.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/codec/common.h b/src/codec/common.h index 98665d7..1b468cb 100644 --- a/src/codec/common.h +++ b/src/codec/common.h @@ -6,7 +6,10 @@ static inline void *camu_page_alloc(size_t size) { #ifdef AL_HAVE_POSIX_MEMALIGN void *ptr = NULL; - al_posix_memalign(&ptr, al_page_size, size); + if (al_posix_memalign(&ptr, al_page_size, size) != 0) { + // For possible EINVAL rather than ENOMEM. + return NULL; + } return ptr; #else return al_malloc(size); |