shithub: riscv

Download patch

ref: 31c3941e872f71664ed9f0bc71341c38ec515dc2
parent: bf04ac517328b9e80908a2a761af36b873002f47
author: cinap_lenrek <[email protected]>
date: Sat Mar 12 16:44:58 EST 2016

ip/gping: set display->locking before starting mouseproc (race)

--- a/sys/src/cmd/ip/gping.c
+++ b/sys/src/cmd/ip/gping.c
@@ -1018,10 +1018,10 @@
 		fprint(2, "%s: initdraw failed: %r\n", argv0);
 		exits("initdraw");
 	}
+	display->locking = 1;	/* tell library we're using the display lock */
 	colinit();
 	einit(Emouse);
 	startproc(mouseproc, 0);
-	display->locking = 1;	/* tell library we're using the display lock */
 
 	resize();