]> rtime.felk.cvut.cz Git - orte.git/blobdiff - orte/include/ul_gavlrepcust.h
Merge branch 'master' of https://github.com/Vajnar/orte
[orte.git] / orte / include / ul_gavlrepcust.h
index 619feb8566981bd826baf0d64cf64db340b48db5..f1384705cbf9fb28b4a63fce6066ff60f36ea462 100644 (file)
@@ -1,3 +1,26 @@
+/*******************************************************************
+  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
 
@@ -124,7 +147,6 @@ int cust_prefix##_delete_node(cust_root_t *root, gavl_node_t *node)\
 \
 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;\
@@ -132,8 +154,7 @@ int cust_prefix##_delete(cust_root_t *root, cust_item_t *item)\
   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)\