The string_completiion_t callback signature of the Zookeeper C API is:
typedef void(* string_completion_t)(int rc, const char *value, const void *data)
That means that when the callback is called, the user provided data is
returned as a const void and cannot be modified by client code, which
kind of defeats the purpose of passing any data in the first place.
Is there any reason why this parameter needs to be const?
typedef void(* string_completion_t)(int rc, const char *value, const void *data)
That means that when the callback is called, the user provided data is
returned as a const void and cannot be modified by client code, which
kind of defeats the purpose of passing any data in the first place.
Is there any reason why this parameter needs to be const?