Use a single socket for communication; change to an sexp-based protocol.
authorLudovic Courtès <ludo@gnu.org>
Sun, 24 Nov 2013 22:28:19 +0000 (23:28 +0100)
committerLudovic Courtès <ludo@gnu.org>
Sun, 24 Nov 2013 22:28:19 +0000 (23:28 +0100)
commitb9c8de281745a8bf5f449c41e50d92999f7a143f
tree058025d4f5bddbddd2ffbb6250b6117fe66a9a84
parent4fde81e263ad0314c4ce667e05763ad5a20c2bfd
Use a single socket for communication; change to an sexp-based protocol.

* modules/dmd/comm.scm (<sender>, initialize, send-data, <receiver>,
  initialize, receive-data): Remove.
  (<dmd-command>): New record type.
  (dmd-command, open-connection, read-command, write-command): New
  procedures.
  (extra-output-sender, open-extra-sender, close-extra-sender,
  without-extra-output): Remove.
  (%current-client-socket): New variable.
* modules/dmd/service.scm (respawn-service): Remove use of
  'without-extra-output'.
* modules/dmd/support.scm (default-socket-file): Change to /socket.
  (default-deco-socket-file): Remove.
* modules/deco.scm (main): Remove --result-socket option.  Use
  'open-connection' instead of <sender> and <receiver>.  Use
  'write-command' instead of 'send-data'.  Use 'read-line' instead of
  'receive-data'.
* modules/dmd.scm (open-server-socket): New procedure.
  (main): Use it.  Remove handshake.
  (process-connection): New procedure.
  (process-command): Expect COMMAND to be a <dmd-command>; use 'match'.
modules/deco.scm
modules/dmd.scm
modules/dmd/comm.scm
modules/dmd/service.scm
modules/dmd/support.scm