| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
| |
We use macros to generate message bodies for each of the various
variants, reducing source code size (but not compiled size). The
documentation is updated to indicate each of these variants.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This makes the operations that work on headers start with
nni_msg_header or nng_msg_header. It also renames _trunc to
_chop (same strlen as _trim), and renames prepend to insert.
We add a shorthand for clearing message content, and make
better use of the endian safe 32-bit accessors too.
This also fixes a bug in inserting large headers into messages.
A test suite for message handling is included.
|
| |
|
|
|
|
|
|
|
|
| |
The PAIR_V1 protocol supports both raw and cooked modes, and has loop
prevention included. It also has a polyamorous mode, wherein it allows
multiple connections to be established. In polyamorous mode (set by
an option), the sender requests a paritcular pipe by setting it on the
message.
We default to PAIR_V1 now.
|
| | |
|
| |
|
|
|
|
|
| |
The use of a single function to get both size and length actually
turned out to be awkward to use; better to have separate functions
to get each. While here, disable some of the initialization/fork
checks, because it turns out they aren't needed.
|
| |
|
|
|
|
|
| |
This uncovered a few problems - inproc was not moving the headers
to the body on transmit, and the message chunk allocator had a serious
bug leading to memory corruption. I've also added a message dumper,
which turns out to be incredibly useful during debugging.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
Instead of supplying a pipe, and expecting that the info there would be included
we use nng_msg_getopt(). This will be enabled by the app asking for extended
information by setting an option, we don't copy the data for every app (most won't
care). This means we don't have to worry about reference counting the pipe for
the life of associated messages.
|
| | |
|
| |
|
|
| |
code with uncrustify. (Minor adjustments.) No more arguments!
|
| |
|