Provide a means to enable debug tracing. Handle the case where the entire buffer is not consumed by librsync.
Define return and argument types for all called functions. Hopefully this solves segfault on 64 bit systems.