aboutsummaryrefslogtreecommitdiffstats
path: root/src/env.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/env.c')
-rw-r--r--src/env.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/env.c b/src/env.c
index e5cb954a..e67b42c0 100644
--- a/src/env.c
+++ b/src/env.c
@@ -47,6 +47,10 @@ serd_env_new(const SerdNode* base_uri)
void
serd_env_free(SerdEnv* env)
{
+ if (!env) {
+ return;
+ }
+
for (size_t i = 0; i < env->n_prefixes; ++i) {
serd_node_free(&env->prefixes[i].name);
serd_node_free(&env->prefixes[i].uri);