mirror of
https://github.com/msgpack/msgpack-c.git
synced 2025-11-03 11:26:21 +01:00
Add msgpack_object_print_buffer() function
In order to print the msgpack object in a memory buffer.
This commit is contained in:
committed by
Stefan Mititelu
parent
42181289ed
commit
4fa661a63d
@@ -98,6 +98,9 @@ typedef struct msgpack_object_kv {
|
||||
MSGPACK_DLLEXPORT
|
||||
void msgpack_object_print(FILE* out, msgpack_object o);
|
||||
|
||||
MSGPACK_DLLEXPORT
|
||||
int msgpack_object_print_buffer(char *buffer, uint32_t buffer_size, msgpack_object o);
|
||||
|
||||
MSGPACK_DLLEXPORT
|
||||
bool msgpack_object_equal(const msgpack_object x, const msgpack_object y);
|
||||
|
||||
|
||||
@@ -14,6 +14,11 @@
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stddef.h>
|
||||
|
||||
#if defined(_MSC_VER) && _MSC_VER <= 1800
|
||||
# define snprintf(buf, len, format,...) _snprintf_s(buf, len, len, format, __VA_ARGS__)
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER) && _MSC_VER < 1600
|
||||
typedef signed __int8 int8_t;
|
||||
typedef unsigned __int8 uint8_t;
|
||||
|
||||
Reference in New Issue
Block a user