aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2021-07-08 11:55:45 -0400
committerDavid Robillard <d@drobilla.net>2022-01-13 15:33:54 -0500
commit942463f2a3b970a9cc730d8dd58decaff8924178 (patch)
treeaef9a9f2afe78a75805da230cf6759409095335e
parent5126deddc9ef239d1f65e21327cb440fe7a67031 (diff)
downloadserd-942463f2a3b970a9cc730d8dd58decaff8924178.tar.gz
serd-942463f2a3b970a9cc730d8dd58decaff8924178.tar.bz2
serd-942463f2a3b970a9cc730d8dd58decaff8924178.zip
Remove redundant null check in serd_env_set_base_uri()
The env parameter here is declared as nonnull in the API, so it is an error to call it with NULL (which clang can statically flag as a warning).
-rw-r--r--src/env.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/env.c b/src/env.c
index bea38a6d..bc6a159f 100644
--- a/src/env.c
+++ b/src/env.c
@@ -74,7 +74,7 @@ serd_env_base_uri(const SerdEnv* const env, SerdURIView* const out)
SerdStatus
serd_env_set_base_uri(SerdEnv* const env, const SerdNode* const uri)
{
- if (!env || (uri && uri->type != SERD_URI)) {
+ if (uri && uri->type != SERD_URI) {
return SERD_ERR_BAD_ARG;
}