Introduction
Introduction Statistics Contact Development Disclaimer Help
Fix synchronization issue with atoms - surf - surf browser, a WebKit based brow…
git clone git://git.suckless.org/surf
Log
Files
Refs
README
LICENSE
---
commit f5be376ccc1fef96722df610c4783e99ce1e944e
parent 5e2216c41434219e60ca52bc5f10d34fddbca964
Author: Quentin Rameau <[email protected]>
Date: Fri, 12 May 2017 00:28:24 +0200
Fix synchronization issue with atoms
Be sure to sync after setting an atom.
Sync too before reading one.
Diffstat:
M surf.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/surf.c b/surf.c
@@ -530,10 +530,10 @@ geturi(Client *c)
void
setatom(Client *c, int a, const char *v)
{
- XSync(dpy, False);
XChangeProperty(dpy, c->xid,
atoms[a], XA_STRING, 8, PropModeReplace,
(unsigned char *)v, strlen(v) + 1);
+ XSync(dpy, False);
}
const char *
@@ -545,6 +545,7 @@ getatom(Client *c, int a)
unsigned long ldummy;
unsigned char *p = NULL;
+ XSync(dpy, False);
XGetWindowProperty(dpy, c->xid, atoms[a], 0L, BUFSIZ, False, XA_STRING,
&adummy, &idummy, &ldummy, &ldummy, &p);
if (p)
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.