[erlang-questions] driver_create_port/4 and binary mode
Tue Apr 16 13:27:16 CEST 2019
I have problems setting binary mode in a port driver.
I am trying to use the RDMA driver
Just like with TCP, the server side creates a new port (calling
erl_driver:driver_create_port/4) upon accept. I cannot persuade this port
to return binaries instead of lists. The client side does not create a new
port and works without problem.
I tried to include the binary option in various places or passing it with
setopts, or calling set_port_control_flags(new_port,
PORT_CONTROL_FLAG_BINARY) at C level without luck. Debugging into the
emulator I saw that I was able to influence the 'control_flags' field of
the Port struct but that was apparently not enough. Perhaps its 'state'
field is influential, at least, that is read by get_port_flags. Am I making
some trivial error here?
Thanks, best regards
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions