aboutsummaryrefslogtreecommitdiffstats
path: root/src/serd_internal.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/serd_internal.h')
-rw-r--r--src/serd_internal.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/serd_internal.h b/src/serd_internal.h
index 39f8d503..d81d0b34 100644
--- a/src/serd_internal.h
+++ b/src/serd_internal.h
@@ -157,10 +157,9 @@ serd_bulk_sink_flush(SerdBulkSink* bsink)
static inline void
serd_bulk_sink_free(SerdBulkSink* bsink)
{
- if (bsink) {
- serd_bulk_sink_flush(bsink);
- free(bsink->buf);
- }
+ serd_bulk_sink_flush(bsink);
+ free(bsink->buf);
+ bsink->buf = NULL;
}
static inline size_t