MCPcopy Create free account
hub / github.com/apache/httpd / dav_register_liveprop_namespace

Function dav_register_liveprop_namespace

modules/dav/main/liveprop.c:36–54  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34}
35
36static void dav_register_liveprop_namespace(apr_pool_t *p, const char *uri)
37{
38 long value;
39
40 if (dav_liveprop_uris == NULL) {
41 dav_liveprop_uris = apr_hash_make(p);
42 apr_pool_cleanup_register(p, NULL, dav_cleanup_liveprops, apr_pool_cleanup_null);
43 }
44
45 value = (long)apr_hash_get(dav_liveprop_uris, uri, APR_HASH_KEY_STRING);
46 if (value != 0) {
47 /* already registered */
48 return;
49 }
50
51 /* start at 1, and count up */
52 apr_hash_set(dav_liveprop_uris, uri, APR_HASH_KEY_STRING,
53 (void *)++dav_liveprop_count);
54}
55
56DAV_DECLARE(long) dav_get_liveprop_ns_index(const char *uri)
57{

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected