From 9076b433d18b5db1a1987fe99ca7c70808f22b0e Mon Sep 17 00:00:00 2001 From: Thomas Jarosch Date: Thu, 1 Jan 2015 23:45:24 +0100 Subject: PictureFlow: Add move callback for buflib allocations If we don't provide a callback to buflib_alloc(), the buffer is always movable (to reduce fragmentation). Since we pass our buffer to functions that call yield(), this could lead to memory corruption on buflib compaction. Change-Id: Id1fad1822479d692551c55cb8bc87cea7b78f759 --- firmware/buflib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'firmware/buflib.c') diff --git a/firmware/buflib.c b/firmware/buflib.c index 9ee721af1f..a47f0a0e62 100644 --- a/firmware/buflib.c +++ b/firmware/buflib.c @@ -677,7 +677,7 @@ buflib_free(struct buflib_context *ctx, int handle_num) else { /* Otherwise, set block to the newly-freed block, and mark it free, before - * continuing on, since the code below exects block to point to a free + * continuing on, since the code below expects block to point to a free * block which may have free space after it. */ block = freed_block; -- cgit