summaryrefslogtreecommitdiff
path: root/msgpack/pack_template.h
diff options
context:
space:
mode:
authorfrsyuki <frsyuki@5a5092ae-2292-43ba-b2d5-dcab9c1a2731>2009-02-15 09:09:58 +0000
committerfrsyuki <frsyuki@5a5092ae-2292-43ba-b2d5-dcab9c1a2731>2009-02-15 09:09:58 +0000
commit1ad04b22d8d3e5267ceec7fc1527651ee0eb0ffe (patch)
tree32306ccc1f374c72440de881b928df9e945bd99f /msgpack/pack_template.h
parent921b0ff62ec99e9339d6cfaa6ba724ae7bb5f9ce (diff)
downloadmsgpack-python-1ad04b22d8d3e5267ceec7fc1527651ee0eb0ffe.tar.gz
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
Diffstat (limited to 'msgpack/pack_template.h')
-rw-r--r--msgpack/pack_template.h7
1 files changed, 5 insertions, 2 deletions
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