about summary refs log tree commit diff
path: root/absl/base/internal/malloc_extension.cc
diff options
context:
space:
mode:
Diffstat (limited to 'absl/base/internal/malloc_extension.cc')
-rw-r--r--absl/base/internal/malloc_extension.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/absl/base/internal/malloc_extension.cc b/absl/base/internal/malloc_extension.cc
index 3da981ce06a3..d48ec5bcf548 100644
--- a/absl/base/internal/malloc_extension.cc
+++ b/absl/base/internal/malloc_extension.cc
@@ -29,6 +29,13 @@ namespace base_internal {
 SysAllocator::~SysAllocator() {}
 void SysAllocator::GetStats(char* buffer, int) { buffer[0] = 0; }
 
+// Dummy key method to avoid weak vtable.
+void MallocExtensionWriter::UnusedKeyMethod() {}
+
+void StringMallocExtensionWriter::Write(const char* buf, int len) {
+  out_->append(buf, len);
+}
+
 // Default implementation -- does nothing
 MallocExtension::~MallocExtension() { }
 bool MallocExtension::VerifyAllMemory() { return true; }