struct evbuffer_cb_info info;
size_t new_size;
uint32_t mask, masked_val;
+ int clear = 1;
if (running_deferred) {
mask = EVBUFFER_CB_NODEFER|EVBUFFER_CB_ENABLED;
} else if (buffer->deferred_cbs) {
mask = EVBUFFER_CB_NODEFER|EVBUFFER_CB_ENABLED;
masked_val = EVBUFFER_CB_NODEFER|EVBUFFER_CB_ENABLED;
+/* Don't zero-out n_add/n_del, since */
+ clear = 0;
} else {
mask = EVBUFFER_CB_ENABLED;
masked_val = EVBUFFER_CB_ENABLED;
#include "util-internal.h"
#include "defer-internal.h"
+/* Experimental cb flag: "never deferred" */
+#define EVBUFFER_CB_NODEFER 2
+
#ifdef WIN32
#include <winsock2.h>
#endif
void *cbarg;
/** Currently set flags on this callback. */
ev_uint32_t flags;
-#if 0
- /** Size of the evbuffer before this callback was suspended, or 0
- if this callback is not suspended. */
- size_t size_before_suspend;
-#endif
};
struct bufferevent;
* should not be invoked. */
#define EVBUFFER_CB_ENABLED 1
-/* Experimental cb flag: "never deferred" */
-#define EVBUFFER_CB_NODEFER 2
-
/** Change the flags that are set for a callback on a buffer by adding more.
@param buffer the evbuffer that the callback is watching.