ipc: strip machinery no peer uses; keep client state in one Keyreq
ipc.c: an AF_UNIX nonblocking connect completes at once or fails with EAGAIN, so the EINPROGRESS/poll/SO_ERROR path and the fcntl juggling were dead; the deadline plumbing checked a clock that cannot fail and re-tested the deadline before every transfer although only waitfd blocks; readfield's truncation and discard loop served the unit test, since every caller owns char[Ipcfieldmax+1]; NULL-argument checks on in-tree encoders are gone (peer validation stays). The primary key frame is Ipckey, not 'legacy'; ipckeysym names the keysym mapping. srv.c: the per-connection capability and caret already lived in the persistent Keyreq; the mirror locals and 'negotiated' flag guarded a protocol rule no client relied on. proccreate never fails in libthread. gtk: focus-out no longer round-trips a reset before closing the socket that releases the engine; the caret dedup compares the packed frame; srvconnect's preedit no-ops and the insimple flag are gone.
This commit is contained in:
@@ -204,7 +204,7 @@ request(Server *s, int fd)
|
||||
e.type = Ecaret;
|
||||
record(s, &e);
|
||||
return 1;
|
||||
case Ipclegacy:
|
||||
case Ipckey:
|
||||
ipcunpackreq(buf, &want, &mod, &key);
|
||||
e.want = want;
|
||||
e.key = key;
|
||||
@@ -854,9 +854,8 @@ main(int argc, char **argv)
|
||||
first = eventcount(&srv);
|
||||
closes = closecount(&srv);
|
||||
gtk_im_context_focus_out(ctx);
|
||||
Check(waitcount(&srv, first + 1) && getevent(&srv, first).type == Ereset,
|
||||
"focus-out reset missing");
|
||||
Check(waitclose(&srv, closes + 1), "focus-out did not close connection");
|
||||
Check(eventcount(&srv) == first, "focus-out sent a request before closing");
|
||||
Check(strcmp(log.event, "CE") == 0, "focus-out clear order was %s", log.event);
|
||||
|
||||
/* Dispose is repeatable, closes the connection, and emits no preedit. */
|
||||
|
||||
Reference in New Issue
Block a user