From 14ce0c1bcbcc5c2dd385bacca84ef7b171608f64 Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Mon, 12 Aug 2019 23:31:17 +0900 Subject: [PATCH] restorable: Bug fix: Lock before resolving stale states --- internal/restorable/images.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/restorable/images.go b/internal/restorable/images.go index 540ddc5f0..d0d66f05d 100644 --- a/internal/restorable/images.go +++ b/internal/restorable/images.go @@ -57,7 +57,7 @@ var theImages = &images{ // ResolveStaleImages is intended to be called at the end of a frame. func ResolveStaleImages() { // Until the begin o the frame (by RestoreIfNeeded, any operations are locked. - defer theImages.m.Lock() + theImages.m.Lock() graphicscommand.FlushCommands() if !needsRestoring() {