Simplify and tidy netint.[ch], tube.c and add netint tests. by dbaarda · Pull Request #183 · librsync/librsync

added 4 commits

December 3, 2019 18:57
Add tests/netint_test.c and CMakeLists.txt changes to test rs_int_len().

In netint.[ch] replace runtime checks for invalid arguments with assert()
statements and tidy the argument names, variable names, and ordering. Replace
`unsigned char` arguments with `rs_byte_t`. Add an assert to rs_int_len() to
require the argument is positive.
Make code variables and structure more consistent. Add extra assert() check to
rs_tube_copy_from_scoop(). Replace fatal runtime check with assert() in
rs_tube_write().

@dbaarda dbaarda changed the title Tidy netint.[ch] and add tests. Simplify and tidy netint.[ch], tube.c and add netint tests.

Dec 6, 2019