+/*******************************************************************
+ uLan Utilities Library - C library of basic reusable constructions
+
+ ul_gavlrepcust.h - custom trees with allowed repeat of keys
+
+ (C) Copyright 2003-2004 by Pavel Pisa - Originator
+
+ The uLan utilities library can be used, copied and modified under
+ next licenses
+ - GPL - GNU General Public License
+ - LGPL - GNU Lesser General Public License
+ - MPL - Mozilla Public License
+ - and other licenses added by project originators
+ Code can be modified and re-distributed under any combination
+ of the above listed licenses. If contributor does not agree with
+ some of the licenses, he/she can delete appropriate line.
+ Warning, if you delete all lines, you are not allowed to
+ distribute source code and/or binaries utilizing code.
+
+ See files COPYING and README for details.
+
+ *******************************************************************/
+
#ifndef _UL_GAVLREPCUST_H
#define _UL_GAVLREPCUST_H
\
int cust_prefix##_delete(cust_root_t *root, cust_item_t *item)\
{\
- int ret;\
gavl_node_t *n, *p;\
if(!item) return -1;\
n=&item->cust_item_node;\
for(p=n; p->parent; p=p->parent);\
if(p!=root->cust_root_node)\
return -1;\
- ret=gavl_delete_primitive(&root->cust_root_node, n);\
- return 1;\
+ return gavl_delete_primitive(&root->cust_root_node, n);\
}\
\
gavl_node_t *cust_prefix##_first_node(const cust_root_t *root)\