summaryrefslogtreecommitdiff
path: root/libbuf/buf.c
diff options
context:
space:
mode:
authorFreeArtMan <dos21h@gmail.com>2019-10-06 14:36:17 +0100
committerFreeArtMan <dos21h@gmail.com>2019-10-06 14:36:17 +0100
commit786bd1e76c6806a4c9272814f9ffe7d901998e4e (patch)
tree8b1e38e48a766c5a8dbad7f00ffb63d09376426c /libbuf/buf.c
parent8a8e0941dd2ab5f089662362a30c91e16de18ce0 (diff)
downloadihe-786bd1e76c6806a4c9272814f9ffe7d901998e4e.tar.gz
ihe-786bd1e76c6806a4c9272814f9ffe7d901998e4e.zip
Fix seek command, tested/works relative seek, and hex positioning support
Diffstat (limited to 'libbuf/buf.c')
-rw-r--r--libbuf/buf.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libbuf/buf.c b/libbuf/buf.c
index b62eb13..f2eaee4 100644
--- a/libbuf/buf.c
+++ b/libbuf/buf.c
@@ -318,6 +318,7 @@ int Buf::realloc(int size)
ptr = (char *)::realloc(this->buf, size);
if (ptr != NULL)
{
+ free(this->buf);
this->buf = ptr;
this->buf_size = size;
}