s4:ldb_msg_check_string_attribute - add a comment about the result values
authorMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>
Sun, 18 Oct 2009 16:13:17 +0000 (18:13 +0200)
committerMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>
Sun, 18 Oct 2009 16:16:31 +0000 (18:16 +0200)
source4/lib/ldb/common/ldb_msg.c
source4/lib/ldb/include/ldb.h

index bf607fd4e6dcd6d542f237559fd98478257a7ff8..a8ea52b0b17f4c74f9f2cdca3d0e10b77fd2f795 100644 (file)
@@ -890,7 +890,11 @@ void ldb_dump_results(struct ldb_context *ldb, struct ldb_result *result, FILE *
        }
 }
 
-int ldb_msg_check_string_attribute(const struct ldb_message *msg, const char *name, const char *value)
+/*
+  checks for a string attribute. Returns "1" on match and otherwise "0".
+*/
+int ldb_msg_check_string_attribute(const struct ldb_message *msg,
+                                  const char *name, const char *value)
 {
        struct ldb_message_element *el;
        struct ldb_val val;
index 69d052b0ebc42be090130fb2ded8d3a716dbba2a..2511fecefb46e9001554fefa323ababff5d7502f 100644 (file)
@@ -1807,6 +1807,15 @@ struct ldb_message *ldb_msg_diff(struct ldb_context *ldb,
                                 struct ldb_message *msg1,
                                 struct ldb_message *msg2);
 
+/**
+   Tries to find a certain string attribute in a message
+
+   \param msg the message to check
+   \param name attribute name
+   \param value attribute value
+
+   \return 1 on match and 0 otherwise.
+*/
 int ldb_msg_check_string_attribute(const struct ldb_message *msg,
                                   const char *name,
                                   const char *value);