liveprop.c revision 75ba48124689705b1eee2b4fe10fe24a2d2467cd
6ae232055d4d8a97267517c5e50074c2c819941and/* ====================================================================
6ae232055d4d8a97267517c5e50074c2c819941and * The Apache Software License, Version 1.1
6ae232055d4d8a97267517c5e50074c2c819941and * Copyright (c) 2000 The Apache Software Foundation. All rights
6ae232055d4d8a97267517c5e50074c2c819941and * reserved.
6ae232055d4d8a97267517c5e50074c2c819941and * Redistribution and use in source and binary forms, with or without
6ae232055d4d8a97267517c5e50074c2c819941and * modification, are permitted provided that the following conditions
6ae232055d4d8a97267517c5e50074c2c819941and * are met:
6ae232055d4d8a97267517c5e50074c2c819941and * 1. Redistributions of source code must retain the above copyright
6ae232055d4d8a97267517c5e50074c2c819941and * notice, this list of conditions and the following disclaimer.
6ae232055d4d8a97267517c5e50074c2c819941and * 2. Redistributions in binary form must reproduce the above copyright
3f08db06526d6901aa08c110b5bc7dde6bc39905nd * notice, this list of conditions and the following disclaimer in
6ae232055d4d8a97267517c5e50074c2c819941and * the documentation and/or other materials provided with the
6ae232055d4d8a97267517c5e50074c2c819941and * distribution.
b43f840409794ed298e8634f6284741f193b6c4ftakashi * 3. The end-user documentation included with the redistribution,
6ae232055d4d8a97267517c5e50074c2c819941and * if any, must include the following acknowledgment:
b43f840409794ed298e8634f6284741f193b6c4ftakashi * "This product includes software developed by the
c04f76acce77126cf88b09350e56ea8c6b4a064enilgun * Apache Software Foundation (http://www.apache.org/)."
6ae232055d4d8a97267517c5e50074c2c819941and * Alternately, this acknowledgment may appear in the software itself,
91f378b5a10f2d83820902ed10ba7967a3920c18nilgun * if and wherever such third-party acknowledgments normally appear.
6ae232055d4d8a97267517c5e50074c2c819941and * 4. The names "Apache" and "Apache Software Foundation" must
b43f840409794ed298e8634f6284741f193b6c4ftakashi * not be used to endorse or promote products derived from this
b43f840409794ed298e8634f6284741f193b6c4ftakashi * software without prior written permission. For written
b43f840409794ed298e8634f6284741f193b6c4ftakashi * permission, please contact apache@apache.org.
6ae232055d4d8a97267517c5e50074c2c819941and * 5. Products derived from this software may not be called "Apache",
6ae232055d4d8a97267517c5e50074c2c819941and * nor may "Apache" appear in their name, without prior written
6ae232055d4d8a97267517c5e50074c2c819941and * permission of the Apache Software Foundation.
6ae232055d4d8a97267517c5e50074c2c819941and * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
6ae232055d4d8a97267517c5e50074c2c819941and * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
6ae232055d4d8a97267517c5e50074c2c819941and * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
6ae232055d4d8a97267517c5e50074c2c819941and * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
6ae232055d4d8a97267517c5e50074c2c819941and * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
6ae232055d4d8a97267517c5e50074c2c819941and * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
6ae232055d4d8a97267517c5e50074c2c819941and * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
6ae232055d4d8a97267517c5e50074c2c819941and * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
6ae232055d4d8a97267517c5e50074c2c819941and * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
6ae232055d4d8a97267517c5e50074c2c819941and * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
6ae232055d4d8a97267517c5e50074c2c819941and * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
6ae232055d4d8a97267517c5e50074c2c819941and * SUCH DAMAGE.
6ae232055d4d8a97267517c5e50074c2c819941and * ====================================================================
6ae232055d4d8a97267517c5e50074c2c819941and * This software consists of voluntary contributions made by many
6ae232055d4d8a97267517c5e50074c2c819941and * individuals on behalf of the Apache Software Foundation. For more
6ae232055d4d8a97267517c5e50074c2c819941and * information on the Apache Software Foundation, please see
6ae232055d4d8a97267517c5e50074c2c819941andstatic int dav_liveprop_count = 0;
6ae232055d4d8a97267517c5e50074c2c819941andvoid dav_register_liveprop_namespace(ap_pool_t *p, const char *uri)
6ae232055d4d8a97267517c5e50074c2c819941and /* ### ignore the pool; it is NULL right now */
6ae232055d4d8a97267517c5e50074c2c819941and ap_register_cleanup(p, NULL, dav_cleanup_liveprops, ap_null_cleanup);
6ae232055d4d8a97267517c5e50074c2c819941and if (value != 0) {
6ae232055d4d8a97267517c5e50074c2c819941and /* already registered */
6ae232055d4d8a97267517c5e50074c2c819941and /* start at 1, and count up */
6ae232055d4d8a97267517c5e50074c2c819941and ap_hash_set(dav_liveprop_uris, uri, 0, (void *)++dav_liveprop_count);
6ae232055d4d8a97267517c5e50074c2c819941andvoid dav_add_all_liveprop_xmlns(ap_pool_t *p, ap_text_header *phdr)
6ae232055d4d8a97267517c5e50074c2c819941and const void *key;
6ae232055d4d8a97267517c5e50074c2c819941and const char *s;