From 1ad04b22d8d3e5267ceec7fc1527651ee0eb0ffe Mon Sep 17 00:00:00 2001 From: frsyuki Date: Sun, 15 Feb 2009 09:09:58 +0000 Subject: lang/c/msgpack: divide pack_raw() into pack_raw() and pack_raw_body() git-svn-id: file:///Users/frsyuki/project/msgpack-git/svn/x@74 5a5092ae-2292-43ba-b2d5-dcab9c1a2731 --- msgpack/pack_template.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'msgpack') diff --git a/msgpack/pack_template.h b/msgpack/pack_template.h index 69c7345..1dbf6fd 100644 --- a/msgpack/pack_template.h +++ b/msgpack/pack_template.h @@ -282,7 +282,7 @@ msgpack_pack_inline_func(map)(msgpack_pack_user x, unsigned int n) * Raw */ -msgpack_pack_inline_func(raw)(msgpack_pack_user x, const void* b, size_t l) +msgpack_pack_inline_func(raw)(msgpack_pack_user x, size_t l) { if(l < 32) { unsigned char d = 0xa0 | l; @@ -296,9 +296,12 @@ msgpack_pack_inline_func(raw)(msgpack_pack_user x, const void* b, size_t l) unsigned char buf[5] = {0xdb, STORE_BE32(d)}; msgpack_pack_append_buffer(x, buf, 5); } - msgpack_pack_append_buffer(x, (const unsigned char*)b, l); } +msgpack_pack_inline_func(raw_body)(msgpack_pack_user x, const void* b, size_t l) +{ + msgpack_pack_append_buffer(x, (const unsigned char*)b, l); +} #undef msgpack_pack_inline_func #undef msgpack_pack_user -- cgit v1.2.1