s4-ldb: Write more explanatory comment for ldb_msg_add()
authorKamen Mazdrashki <kamenim@samba.org>
Fri, 9 Jul 2010 16:24:57 +0000 (19:24 +0300)
committerKamen Mazdrashki <kamenim@samba.org>
Sat, 10 Jul 2010 20:03:14 +0000 (23:03 +0300)
source4/lib/ldb/common/ldb_msg.c

index 186861a2439d31ea75f6ebf7b39ee0c0a4401c52..719373ea3be1cece7ad2b39f2d487f68a32308c4 100644 (file)
@@ -150,9 +150,14 @@ int ldb_msg_add_empty(     struct ldb_message *msg,
        return LDB_SUCCESS;
 }
 
-/*
-  add an empty element to a message
-*/
+/**
+ * Adds an element to a message.
+ *
+ * NOTE: Ownership of ldb_message_element fields
+ *       is NOT transferred. Thus, if el pointer
+ *       is invalidated for some reason, this will
+ *       corrupt msg contents also
+ */
 int ldb_msg_add(struct ldb_message *msg, 
                const struct ldb_message_element *el, 
                int flags)