From b5b1d4e9073ab29c4af2e0661a165280c8e98b8c Mon Sep 17 00:00:00 2001 From: Ilya Lipnitskiy Date: Wed, 27 Nov 2013 15:53:15 -0800 Subject: [PATCH] protobuf-c/protobuf-c.{c,h}: remove the unused protobuf_c_system_allocator --- protobuf-c/protobuf-c.c | 14 -------------- protobuf-c/protobuf-c.h | 6 ------ 2 files changed, 20 deletions(-) diff --git a/protobuf-c/protobuf-c.c b/protobuf-c/protobuf-c.c index 32dfe11..4a870cd 100644 --- a/protobuf-c/protobuf-c.c +++ b/protobuf-c/protobuf-c.c @@ -155,20 +155,6 @@ ProtobufCAllocator protobuf_c_default_allocator = NULL /* allocator_data */ }; -/* Users should NOT modify this structure, - but it's difficult to prevent. - - please modify protobuf_c_default_allocator instead. */ -ProtobufCAllocator protobuf_c_system_allocator = -{ - system_alloc, - system_free, - NULL, /* tmp_alloc */ - 8192, /* max_alloca */ - NULL /* allocator_data */ -}; - - /* === buffer-simple === */ void protobuf_c_buffer_simple_append (ProtobufCBuffer *buffer, diff --git a/protobuf-c/protobuf-c.h b/protobuf-c/protobuf-c.h index f52d7ca..5cc3674 100644 --- a/protobuf-c/protobuf-c.h +++ b/protobuf-c/protobuf-c.h @@ -164,12 +164,6 @@ struct _ProtobufCAllocator */ extern PROTOBUF_C_API ProtobufCAllocator protobuf_c_default_allocator; /* settable */ -/* This is the system allocator, meaning it uses malloc() and free(). - * - * NOTE: please do NOT modify this allocator. - */ -extern PROTOBUF_C_API ProtobufCAllocator protobuf_c_system_allocator; /* use malloc, free etc */ - /* This is the function that our default allocators call when they run out-of-memory. The default behavior of this function is to terminate your program. */