equal
deleted
inserted
replaced
19 // our key/obj |
19 // our key/obj |
20 struct memcache_key key; |
20 struct memcache_key key; |
21 struct memcache_obj obj; |
21 struct memcache_obj obj; |
22 struct memcache_buf buf; |
22 struct memcache_buf buf; |
23 |
23 |
24 // flags to indicate if we have valid obj/buf data |
24 // flags to indicate if we have valid obj/buf data, and if buf.data was allocated by us or supplied by the user |
25 char have_obj, have_buf; |
25 char have_obj, have_buf, is_buf_ours; |
26 |
26 |
27 // our state |
27 // our state |
28 enum memcache_req_state state; |
28 enum memcache_state state; |
29 |
29 |
30 // our user callback argument |
30 // our user callback argument |
31 void *cb_arg; |
31 void *cb_arg; |
32 |
32 |
33 // the conn |
33 // the conn |
79 |
79 |
80 /* |
80 /* |
81 * The request was sent and is now done, and is not associated with the connection anymore. |
81 * The request was sent and is now done, and is not associated with the connection anymore. |
82 * |
82 * |
83 * This will be called before req_reply/req_data, but not before/after req_error. |
83 * This will be called before req_reply/req_data, but not before/after req_error. |
|
84 * |
|
85 * The request will not be accessed anymore after calling this. |
84 */ |
86 */ |
85 void memcache_req_done (struct memcache_req *req); |
87 void memcache_req_done (struct memcache_req *req); |
86 |
88 |
87 /* |
89 /* |
88 * An error occurred, and the request must be abandoned. This will assume that the req is not active or enqueued |
90 * An error occurred, and the request must be abandoned. The request is not active or enqueued anymore. |
89 * anymore, and the req should not be accessed by memcache_* code after this. |
91 * |
|
92 * The request will not be accessed anymore after calling this. |
90 */ |
93 */ |
91 void memcache_req_error (struct memcache_req *req); |
94 void memcache_req_error (struct memcache_req *req); |
92 |
95 |
93 /* |
96 /* |
94 * Free an unused req. Should always be called by the user, not via internal means. |
97 * Free an unused req. Should always be called by the user, not via internal means. |