diff options
author | David Robillard <d@drobilla.net> | 2018-12-30 12:35:47 -0500 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2019-04-13 19:15:32 +0200 |
commit | 7734028901a428267b723f4b956deae91c45c1cf (patch) | |
tree | 6b0e2caa3a26e50f91811c8aa1a5945e0fd314a6 /tests | |
parent | 8f954d7a609c7bf5a955c117c8abbde0eaef3aca (diff) | |
download | serd-7734028901a428267b723f4b956deae91c45c1cf.tar.gz serd-7734028901a428267b723f4b956deae91c45c1cf.tar.bz2 serd-7734028901a428267b723f4b956deae91c45c1cf.zip |
Remove serd_env_foreach()
Diffstat (limited to 'tests')
-rw-r--r-- | tests/serd_test.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/serd_test.c b/tests/serd_test.c index bab255e6..d6c2d1fc 100644 --- a/tests/serd_test.c +++ b/tests/serd_test.c @@ -450,9 +450,11 @@ main(void) SerdNode* lit = serd_new_string("hello"); assert(serd_env_set_prefix(env, b, lit)); - int n_prefixes = 0; + size_t n_prefixes = 0; + SerdSink* count_prefixes_sink = serd_sink_new(&n_prefixes); + serd_sink_set_prefix_func(count_prefixes_sink, count_prefixes); serd_env_set_prefix(env, pre, eg); - serd_env_foreach(env, count_prefixes, &n_prefixes); + serd_env_write_prefixes(env, count_prefixes_sink); assert(n_prefixes == 1); SerdNode* shorter_uri = serd_new_uri("urn:foo"); |