commit f4020b2cc4fe45c9e8bfe47fc73deccd867cf9de from: Hiltjo Posthuma date: Tue Mar 20 20:25:30 2018 UTC fix regression by selecting clipboard text "restore the old behaviour that the primary doesn't get deleted by a simple left click" Patch by Daniel Tameling , thanks! commit - a5a928bfc1dd049780a45e072cb4ee42de7219bf commit + f4020b2cc4fe45c9e8bfe47fc73deccd867cf9de blob - 12bc86b81cb03c663381965eddb664b3015884e6 blob + c343ba2bdaf446aba578a55cb219afb73cf00fda --- x.c +++ x.c @@ -618,6 +618,9 @@ selrequest(XEvent *e) void setsel(char *str, Time t) { + if (!str) + return; + free(xsel.primary); xsel.primary = str;