Commit graph

4 commits

Author SHA1 Message Date
XANTRONIX Development
0fecccd7c3 Missed a spot with patty_ax25_pton() fix 2024-03-01 00:20:47 -05:00
XANTRONIX Development
1f4ffc98ac Implement new patty client code
Implement new patty client code, replacing src/call.c with src/client.c
providing clients with an interface dealing with file descriptors valid
in their process space; this also obviates the need to open a Unix
domain socket to a patty server explicitly, and helps keep track of
sockets opened on the server, locally

Changes:

    * Implement patty_client_new() to handle opening the server Unix
      domain socket, and to allocate a dict for mapping server-side
      sockets with current process file descriptors

    * Reimplement all server calls in src/call.c around the new
      patty_client type; calls which result in the creation of a
      Unix98 PTY by the patty server now handle opening the local PTY
      and setting the file descriptor to raw mode.  Furthermore, these
      calls deal exclusively in terms of current process file
      descriptors

    * Refactor src/server.c to use the new patty_client type and calls

    * Refactor examples/client.c, examples/server.c, examples/ax25dump.c
      to use the new patty_client type and calls

    * Fix a bug in src/server.c, respond_accept() wherein a 0, rather
      than the file descriptor of the socket, is sent to the client as a
      return value
2024-03-01 00:20:46 -05:00
XANTRONIX Development
d4e7933e6b Make examples take callsign as local/remote address 2024-03-01 00:20:46 -05:00
XANTRONIX Development
9f13c67518 Provide shorter names for programs in examples/ 2024-03-01 00:20:46 -05:00
Renamed from examples/testclient-connect.c (Browse further)