From dbd7db7787bbab3c13a9f63b868b585fc4a417ad Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Sun, 12 Apr 2020 13:16:55 +1000 Subject: [PATCH] [common] fix framebuffer_prepare to use atomic_store --- VERSION | 2 +- common/src/framebuffer.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/VERSION b/VERSION index 49410ff2..c200b53b 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -B1-165-gb5f4c639fd+1 \ No newline at end of file +B1-166-g1222fd40b7+1 \ No newline at end of file diff --git a/common/src/framebuffer.c b/common/src/framebuffer.c index 6de5f8a2..7d477be3 100644 --- a/common/src/framebuffer.c +++ b/common/src/framebuffer.c @@ -95,7 +95,7 @@ bool framebuffer_read_fn(const FrameBuffer * frame, FrameBufferReadFn fn, size_t */ void framebuffer_prepare(FrameBuffer * frame) { - frame->wp = 0; + atomic_store(&frame->wp, 0); } bool framebuffer_write(FrameBuffer * frame, const void * src, size_t size)