diff options
author | Lennart Poettering <lennart@poettering.net> | 2007-10-28 19:13:50 +0000 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2007-10-28 19:13:50 +0000 |
commit | a67c21f093202f142438689d3f7cfbdf4ea82eea (patch) | |
tree | 5c3295037f033904bc11ab8b3adae5b7331101e9 /src/pulsecore/memchunk.h | |
parent | 6687dd013169fd8436aa1b45ccdacff074a40d05 (diff) |
merge 'lennart' branch back into trunk.
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1971 fefdeb5f-60dc-0310-8127-8f9354f1896f
Diffstat (limited to 'src/pulsecore/memchunk.h')
-rw-r--r-- | src/pulsecore/memchunk.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/pulsecore/memchunk.h b/src/pulsecore/memchunk.h index 0b982b6d..e6105ace 100644 --- a/src/pulsecore/memchunk.h +++ b/src/pulsecore/memchunk.h @@ -37,11 +37,16 @@ typedef struct pa_memchunk { /* Make a memchunk writable, i.e. make sure that the caller may have * exclusive access to the memblock and it is not read_only. If needed - * the memblock in the structure is replaced by a copy. */ -void pa_memchunk_make_writable(pa_memchunk *c, size_t min); + * the memblock in the structure is replaced by a copy. If min is not + * 0 it is made sure that the returned memblock is at least of the + * specified size, i.e. is enlarged if necessary. */ +pa_memchunk* pa_memchunk_make_writable(pa_memchunk *c, size_t min); /* Invalidate a memchunk. This does not free the cotaining memblock, * but sets all members to zero. */ -void pa_memchunk_reset(pa_memchunk *c); +pa_memchunk* pa_memchunk_reset(pa_memchunk *c); + +/* Map a memory chunk back into memory if it was swapped out */ +pa_memchunk *pa_memchunk_will_need(const pa_memchunk *c); #endif |