libceph: initialize msgpool message types

Initialize the type field for messages in a msgpool.  The caller was doing
this for osd ops, but not for the reply messages.

Reported-by: Alex Elder <elder@inktank.com>
Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
Sage Weil
2012-07-09 14:22:34 -07:00
parent fbb85a478f
commit d50b409fb8
3 changed files with 10 additions and 7 deletions

View File

@@ -11,10 +11,11 @@
struct ceph_msgpool {
const char *name;
mempool_t *pool;
int type; /* preallocated message type */
int front_len; /* preallocated payload size */
};
extern int ceph_msgpool_init(struct ceph_msgpool *pool,
extern int ceph_msgpool_init(struct ceph_msgpool *pool, int type,
int front_len, int size, bool blocking,
const char *name);
extern void ceph_msgpool_destroy(struct ceph_msgpool *pool);