From a64e85acf96bc0c55363fe55c9e9116aef2a8584 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Sat, 12 May 2007 23:38:38 +0000 Subject: resampling works git-svn-id: file:///home/lennart/svn/public/libsydney/trunk@4 9ba3c220-e4d3-45a2-8aa3-73fcc9aff6ce --- malloc.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'malloc.h') diff --git a/malloc.h b/malloc.h index df459ed..d9dcee9 100644 --- a/malloc.h +++ b/malloc.h @@ -8,9 +8,12 @@ #define sa_free free #define sa_malloc0(size) calloc(1, (size)) #define sa_strdup strdup +#define sa_strndup strndup void* sa_memdup(const void* p, size_t size); -#define sa_new(t, n) ((t*) sa_malloc(sizeof(t)*n)) +#define sa_new(t, n) ((t*) sa_malloc(sizeof(t)*(n))) +#define sa_new0(t, n) ((t*) sa_malloc0(sizeof(t)*(n))) +#define sa_newdup(p, t, n) ((t*) sa_memdup(p, sizeof(t)*(n))) #endif -- cgit