remove all '\n' from ldb_debug
authorSumit Bose <sbose@redhat.com>
Fri, 10 Jul 2009 20:44:27 +0000 (22:44 +0200)
committerSimo Sorce <idra@samba.org>
Tue, 14 Jul 2009 15:21:11 +0000 (11:21 -0400)
19 files changed:
source4/lib/ldb/common/ldb.c
source4/lib/ldb/common/ldb_debug.c
source4/lib/ldb/common/ldb_ldif.c
source4/lib/ldb/common/ldb_match.c
source4/lib/ldb/common/ldb_modules.c
source4/lib/ldb/ldb_ildap/ldb_ildap.c
source4/lib/ldb/ldb_ldap/ldb_ldap.c
source4/lib/ldb/ldb_map/ldb_map.c
source4/lib/ldb/ldb_map/ldb_map_inbound.c
source4/lib/ldb/ldb_map/ldb_map_outbound.c
source4/lib/ldb/ldb_tdb/ldb_cache.c
source4/lib/ldb/ldb_tdb/ldb_index.c
source4/lib/ldb/ldb_tdb/ldb_pack.c
source4/lib/ldb/ldb_tdb/ldb_tdb.c
source4/lib/ldb/modules/asq.c
source4/lib/ldb/modules/operational.c
source4/lib/ldb/modules/paged_results.c
source4/lib/ldb/modules/rdn_name.c
source4/lib/ldb/modules/sort.c

index 64ad6832dbb050c32b44db583f7548fa4df4a615..164e5a95a045c6f98c26f616846a11629a455232 100644 (file)
@@ -240,7 +240,7 @@ int ldb_connect(struct ldb_context *ldb, const char *url,
 
        if (ldb_load_modules(ldb, options) != LDB_SUCCESS) {
                ldb_debug(ldb, LDB_DEBUG_FATAL,
-                         "Unable to load modules for %s: %s\n",
+                         "Unable to load modules for %s: %s",
                          url, ldb_errstring(ldb));
                return LDB_ERR_OTHER;
        }
index f8009eb8a345403b64f85fe7985e45b5d22efe4b..7680862c2cd9485ba1470b8b71e27e54adc91f99 100644 (file)
@@ -56,6 +56,7 @@ static void ldb_debug_stderr(void *context, enum ldb_debug_level level,
 {
        if (level <= LDB_DEBUG_WARNING) {
                vfprintf(stderr, fmt, ap);
+               fprintf(stderr, "\n");
        }
 }
 
index d64a9f1c3a813e07c584c854a99fc19b0cc4d50e..d890ff83006215373243057508f5f897e39c12c7 100644 (file)
@@ -296,7 +296,7 @@ int ldb_ldif_write(struct ldb_context *ldb,
                        }
                }
                if (!ldb_changetypes[i].name) {
-                       ldb_debug(ldb, LDB_DEBUG_ERROR, "Error: Invalid ldif changetype %d\n",
+                       ldb_debug(ldb, LDB_DEBUG_ERROR, "Error: Invalid ldif changetype %d",
                                  ldif->changetype);
                        talloc_free(mem_ctx);
                        return -1;
@@ -561,7 +561,7 @@ struct ldb_ldif *ldb_ldif_read(struct ldb_context *ldb,
        
        /* first line must be a dn */
        if (ldb_attr_cmp(attr, "dn") != 0) {
-               ldb_debug(ldb, LDB_DEBUG_ERROR, "Error: First line of ldif must be a dn not '%s'\n", 
+               ldb_debug(ldb, LDB_DEBUG_ERROR, "Error: First line of ldif must be a dn not '%s'",
                          attr);
                goto failed;
        }
@@ -569,7 +569,7 @@ struct ldb_ldif *ldb_ldif_read(struct ldb_context *ldb,
        msg->dn = ldb_dn_from_ldb_val(msg, ldb, &value);
 
        if ( ! ldb_dn_validate(msg->dn)) {
-               ldb_debug(ldb, LDB_DEBUG_ERROR, "Error: Unable to parse dn '%s'\n", 
+               ldb_debug(ldb, LDB_DEBUG_ERROR, "Error: Unable to parse dn '%s'",
                          (char *)value.data);
                goto failed;
        }
@@ -588,8 +588,8 @@ struct ldb_ldif *ldb_ldif_read(struct ldb_context *ldb,
                                }
                        }
                        if (!ldb_changetypes[i].name) {
-                               ldb_debug(ldb, LDB_DEBUG_ERROR, 
-                                         "Error: Bad ldif changetype '%s'\n",(char *)value.data);
+                               ldb_debug(ldb, LDB_DEBUG_ERROR,
+                                         "Error: Bad ldif changetype '%s'",(char *)value.data);
                        }
                        flags = 0;
                        continue;
@@ -638,7 +638,7 @@ struct ldb_ldif *ldb_ldif_read(struct ldb_context *ldb,
                        }
                        if (value.length == 0) {
                                ldb_debug(ldb, LDB_DEBUG_ERROR,
-                                         "Error: Attribute value cannot be empty for attribute '%s'\n", el->name);
+                                         "Error: Attribute value cannot be empty for attribute '%s'", el->name);
                                goto failed;
                        }
                        if (value.data != el->values[el->num_values].data) {
index c622701d308c1c2807ab0c8e5a30085399343bb4..e6ee0de0274e9b5e6f85b39687552bd47d6204d5 100644 (file)
@@ -335,7 +335,7 @@ static int ldb_match_extended(struct ldb_context *ldb,
                }
        }
        if (comp == NULL) {
-               ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb: unknown extended rule_id %s\n",
+               ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb: unknown extended rule_id %s",
                          tree->u.extended.rule_id);
                return -1;
        }
index ae97ef4cced4db84ed7490aee01167165f32abb4..05dffd005a09b8b10d29cc71a80ed996d2976ddb 100644 (file)
@@ -84,13 +84,13 @@ const char **ldb_modules_list_from_string(struct ldb_context *ldb, TALLOC_CTX *m
        /* spaces not admitted */
        modstr = ldb_modules_strdup_no_spaces(mem_ctx, string);
        if ( ! modstr) {
-               ldb_debug(ldb, LDB_DEBUG_FATAL, "Out of Memory in ldb_modules_strdup_no_spaces()\n");
+               ldb_debug(ldb, LDB_DEBUG_FATAL, "Out of Memory in ldb_modules_strdup_no_spaces()");
                return NULL;
        }
 
        modules = talloc_realloc(mem_ctx, modules, char *, 2);
        if ( ! modules ) {
-               ldb_debug(ldb, LDB_DEBUG_FATAL, "Out of Memory in ldb_modules_list_from_string()\n");
+               ldb_debug(ldb, LDB_DEBUG_FATAL, "Out of Memory in ldb_modules_list_from_string()");
                talloc_free(modstr);
                return NULL;
        }
@@ -106,7 +106,7 @@ const char **ldb_modules_list_from_string(struct ldb_context *ldb, TALLOC_CTX *m
                i++;
                modules = talloc_realloc(mem_ctx, modules, char *, i + 2);
                if ( ! modules ) {
-                       ldb_debug(ldb, LDB_DEBUG_FATAL, "Out of Memory in ldb_modules_list_from_string()\n");
+                       ldb_debug(ldb, LDB_DEBUG_FATAL, "Out of Memory in ldb_modules_list_from_string()");
                        return NULL;
                }
 
@@ -239,7 +239,7 @@ int ldb_connect_backend(struct ldb_context *ldb,
 
        if (fn == NULL) {
                ldb_debug(ldb, LDB_DEBUG_FATAL,
-                         "Unable to find backend for '%s'\n", url);
+                         "Unable to find backend for '%s'", url);
                return LDB_ERR_OTHER;
        }
 
@@ -247,7 +247,7 @@ int ldb_connect_backend(struct ldb_context *ldb,
 
        if (ret != LDB_SUCCESS) {
                ldb_debug(ldb, LDB_DEBUG_ERROR,
-                         "Failed to connect to '%s'\n", url);
+                         "Failed to connect to '%s'", url);
                return ret;
        }
        return ret;
@@ -304,18 +304,18 @@ static void *ldb_dso_load_symbol(struct ldb_context *ldb, const char *name,
        path = talloc_asprintf(ldb, "%s/%s.%s", ldb->modules_dir, name, 
                               SHLIBEXT);
 
-       ldb_debug(ldb, LDB_DEBUG_TRACE, "trying to load %s from %s\n", name, path);
+       ldb_debug(ldb, LDB_DEBUG_TRACE, "trying to load %s from %s", name, path);
 
        handle = dlopen(path, RTLD_NOW);
        if (handle == NULL) {
-               ldb_debug(ldb, LDB_DEBUG_WARNING, "unable to load %s from %s: %s\n", name, path, dlerror());
+               ldb_debug(ldb, LDB_DEBUG_WARNING, "unable to load %s from %s: %s", name, path, dlerror());
                return NULL;
        }
 
        sym = (int (*)(void))dlsym(handle, symbol);
 
        if (sym == NULL) {
-               ldb_debug(ldb, LDB_DEBUG_ERROR, "no symbol `%s' found in %s: %s\n", symbol, path, dlerror());
+               ldb_debug(ldb, LDB_DEBUG_ERROR, "no symbol `%s' found in %s: %s", symbol, path, dlerror());
                return NULL;
        }
 
@@ -351,7 +351,7 @@ int ldb_load_modules_list(struct ldb_context *ldb, const char **module_list, str
                }
                
                if (ops == NULL) {
-                       ldb_debug(ldb, LDB_DEBUG_WARNING, "WARNING: Module [%s] not found\n", 
+                       ldb_debug(ldb, LDB_DEBUG_WARNING, "WARNING: Module [%s] not found",
                                  module_list[i]);
                        continue;
                }
@@ -382,7 +382,7 @@ int ldb_init_module_chain(struct ldb_context *ldb, struct ldb_module *module)
        if (module) {
                int ret = module->ops->init_context(module);
                if (ret != LDB_SUCCESS) {
-                       ldb_debug(ldb, LDB_DEBUG_FATAL, "module %s initialization failed\n", module->ops->name);
+                       ldb_debug(ldb, LDB_DEBUG_FATAL, "module %s initialization failed", module->ops->name);
                        return ret;
                }
        }
@@ -428,7 +428,7 @@ int ldb_load_modules(struct ldb_context *ldb, const char *options[])
                if (ret == LDB_ERR_NO_SUCH_OBJECT) {
                        ldb_debug(ldb, LDB_DEBUG_TRACE, "no modules required by the db");
                } else if (ret != LDB_SUCCESS) {
-                       ldb_debug(ldb, LDB_DEBUG_FATAL, "ldb error (%s) occurred searching for modules, bailing out\n", ldb_errstring(ldb));
+                       ldb_debug(ldb, LDB_DEBUG_FATAL, "ldb error (%s) occurred searching for modules, bailing out", ldb_errstring(ldb));
                        talloc_free(mem_ctx);
                        return ret;
                } else {
@@ -436,7 +436,7 @@ int ldb_load_modules(struct ldb_context *ldb, const char *options[])
                        if (res->count == 0) {
                                ldb_debug(ldb, LDB_DEBUG_TRACE, "no modules required by the db");
                        } else if (res->count > 1) {
-                               ldb_debug(ldb, LDB_DEBUG_FATAL, "Too many records found (%d), bailing out\n", res->count);
+                               ldb_debug(ldb, LDB_DEBUG_FATAL, "Too many records found (%d), bailing out", res->count);
                                talloc_free(mem_ctx);
                                return -1;
                        } else {
index 4447d0e09a473b8af1ca6983d73ff8d5f3394f0a..ffde048223f318a12583ff02aa6f286d65110c43 100644 (file)
@@ -790,7 +790,7 @@ static int ildb_connect(struct ldb_context *ldb, const char *url,
 
        status = ldap_connect(ildb->ldap, url);
        if (!NT_STATUS_IS_OK(status)) {
-               ldb_debug(ldb, LDB_DEBUG_ERROR, "Failed to connect to ldap URL '%s' - %s\n",
+               ldb_debug(ldb, LDB_DEBUG_ERROR, "Failed to connect to ldap URL '%s' - %s",
                          url, ldap_errstr(ildb->ldap, module, status));
                goto failed;
        }
@@ -810,14 +810,14 @@ static int ildb_connect(struct ldb_context *ldb, const char *url,
                        const char *password = cli_credentials_get_password(creds);
                        status = ldap_bind_simple(ildb->ldap, bind_dn, password);
                        if (!NT_STATUS_IS_OK(status)) {
-                               ldb_debug(ldb, LDB_DEBUG_ERROR, "Failed to bind - %s\n",
+                               ldb_debug(ldb, LDB_DEBUG_ERROR, "Failed to bind - %s",
                                          ldap_errstr(ildb->ldap, module, status));
                                goto failed;
                        }
                } else {
                        status = ldap_bind_sasl(ildb->ldap, creds, lp_ctx);
                        if (!NT_STATUS_IS_OK(status)) {
-                               ldb_debug(ldb, LDB_DEBUG_ERROR, "Failed to bind - %s\n",
+                               ldb_debug(ldb, LDB_DEBUG_ERROR, "Failed to bind - %s",
                                          ldap_errstr(ildb->ldap, module, status));
                                goto failed;
                        }
index 43a01f75a73baa5f7c3805c745bd6c0ddac07bdb..52c16101bb4ec280dbfd8bd3ae6dbdcdadd563a3 100644 (file)
@@ -219,7 +219,7 @@ static int lldb_search(struct lldb_context *lldb_ac)
        }
 
        if (req->controls != NULL) {
-               ldb_debug(ldb, LDB_DEBUG_WARNING, "Controls are not yet supported by ldb_ldap backend!\n");
+               ldb_debug(ldb, LDB_DEBUG_WARNING, "Controls are not yet supported by ldb_ldap backend!");
        }
 
        ldb_request_set_state(req, LDB_ASYNC_PENDING);
@@ -871,7 +871,7 @@ static int lldb_connect(struct ldb_context *ldb,
 
        ret = ldap_initialize(&lldb->ldap, url);
        if (ret != LDAP_SUCCESS) {
-               ldb_debug(ldb, LDB_DEBUG_FATAL, "ldap_initialize failed for URL '%s' - %s\n",
+               ldb_debug(ldb, LDB_DEBUG_FATAL, "ldap_initialize failed for URL '%s' - %s",
                          url, ldap_err2string(ret));
                goto failed;
        }
@@ -880,7 +880,7 @@ static int lldb_connect(struct ldb_context *ldb,
 
        ret = ldap_set_option(lldb->ldap, LDAP_OPT_PROTOCOL_VERSION, &version);
        if (ret != LDAP_SUCCESS) {
-               ldb_debug(ldb, LDB_DEBUG_FATAL, "ldap_set_option failed - %s\n",
+               ldb_debug(ldb, LDB_DEBUG_FATAL, "ldap_set_option failed - %s",
                          ldap_err2string(ret));
                goto failed;
        }
index 5b4ea7910a75137c8ddea361620d64491e71162d..68e9d3f392987cd78608e7faf276687edd7be561 100644 (file)
@@ -242,7 +242,7 @@ int ldb_next_remote_request(struct ldb_module *module, struct ldb_request *reque
 
        default:
                ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
-                         "Invalid remote request!\n");
+                         "Invalid remote request!");
                return LDB_ERR_OPERATIONS_ERROR;
        }
 
@@ -503,14 +503,14 @@ struct ldb_dn *ldb_dn_map_local(struct ldb_module *module, void *mem_ctx, struct
                case MAP_GENERATE:
                        ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
                                  "MAP_IGNORE/MAP_GENERATE attribute '%s' "
-                                 "used in DN!\n", ldb_dn_get_component_name(dn, i));
+                                 "used in DN!", ldb_dn_get_component_name(dn, i));
                        goto failed;
 
                case MAP_CONVERT:
                        if (map->u.convert.convert_local == NULL) {
                                ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
                                          "'convert_local' not set for attribute '%s' "
-                                         "used in DN!\n", ldb_dn_get_component_name(dn, i));
+                                         "used in DN!", ldb_dn_get_component_name(dn, i));
                                goto failed;
                        }
                        /* fall through */
@@ -578,14 +578,14 @@ struct ldb_dn *ldb_dn_map_remote(struct ldb_module *module, void *mem_ctx, struc
                case MAP_GENERATE:
                        ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
                                  "MAP_IGNORE/MAP_GENERATE attribute '%s' "
-                                 "used in DN!\n", ldb_dn_get_component_name(dn, i));
+                                 "used in DN!", ldb_dn_get_component_name(dn, i));
                        goto failed;
 
                case MAP_CONVERT:
                        if (map->u.convert.convert_remote == NULL) {
                                ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
                                          "'convert_remote' not set for attribute '%s' "
-                                         "used in DN!\n", ldb_dn_get_component_name(dn, i));
+                                         "used in DN!", ldb_dn_get_component_name(dn, i));
                                goto failed;
                        }
                        /* fall through */
@@ -1007,7 +1007,7 @@ static int map_init_dns(struct ldb_module *module, struct ldb_map_context *data,
        dn = ldb_dn_new_fmt(data, ldb, "%s=%s", MAP_DN_NAME, name);
        if ( ! ldb_dn_validate(dn)) {
                ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
-                         "Failed to construct '%s' DN!\n", MAP_DN_NAME);
+                         "Failed to construct '%s' DN!", MAP_DN_NAME);
                return LDB_ERR_OPERATIONS_ERROR;
        }
 
@@ -1018,13 +1018,13 @@ static int map_init_dns(struct ldb_module *module, struct ldb_map_context *data,
        }
        if (res->count == 0) {
                ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
-                         "No results for '%s=%s'!\n", MAP_DN_NAME, name);
+                         "No results for '%s=%s'!", MAP_DN_NAME, name);
                talloc_free(res);
                return LDB_ERR_CONSTRAINT_VIOLATION;
        }
        if (res->count > 1) {
                ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
-                         "Too many results for '%s=%s'!\n", MAP_DN_NAME, name);
+                         "Too many results for '%s=%s'!", MAP_DN_NAME, name);
                talloc_free(res);
                return LDB_ERR_CONSTRAINT_VIOLATION;
        }
index 455740ce590ee27dc0f54a8af5a0072c5da77daa..89037419fbca71fcbf1f34386c0620bc0eb2f7fc 100644 (file)
@@ -73,7 +73,7 @@ static int ldb_msg_el_partition(struct ldb_module *module, struct ldb_message *l
        /* Unknown attribute: ignore */
        if (map == NULL) {
                ldb_debug(ldb, LDB_DEBUG_WARNING, "ldb_map: "
-                         "Not mapping attribute '%s': no mapping found\n",
+                         "Not mapping attribute '%s': no mapping found",
                          old->name);
                goto local;
        }
@@ -86,7 +86,7 @@ static int ldb_msg_el_partition(struct ldb_module *module, struct ldb_message *l
                if (map->u.convert.convert_local == NULL) {
                        ldb_debug(ldb, LDB_DEBUG_WARNING, "ldb_map: "
                                  "Not mapping attribute '%s': "
-                                 "'convert_local' not set\n",
+                                 "'convert_local' not set",
                                  map->local_name);
                        goto local;
                }
@@ -100,7 +100,7 @@ static int ldb_msg_el_partition(struct ldb_module *module, struct ldb_message *l
                if (map->u.generate.generate_remote == NULL) {
                        ldb_debug(ldb, LDB_DEBUG_WARNING, "ldb_map: "
                                  "Not mapping attribute '%s': "
-                                 "'generate_remote' not set\n",
+                                 "'generate_remote' not set",
                                  map->local_name);
                        goto local;
                }
@@ -167,7 +167,7 @@ static int ldb_msg_partition(struct ldb_module *module, struct ldb_message *loca
                /* Skip 'IS_MAPPED' */
                if (ldb_attr_cmp(msg->elements[i].name, IS_MAPPED) == 0) {
                        ldb_debug(ldb, LDB_DEBUG_WARNING, "ldb_map: "
-                                 "Skipping attribute '%s'\n",
+                                 "Skipping attribute '%s'",
                                  msg->elements[i].name);
                        continue;
                }
index ffcefad6be6fdf066cb4b3552f11d5d4e75d6ff5..4487d7e763dd4118f987c49cd7a2c2b75a4f7b92 100644 (file)
@@ -304,7 +304,7 @@ static int ldb_msg_el_merge(struct ldb_module *module, struct ldb_message *local
                if (map->u.convert.convert_remote == NULL) {
                        ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
                                  "Skipping attribute '%s': "
-                                 "'convert_remote' not set\n",
+                                 "'convert_remote' not set",
                                  attr_name);
                        return LDB_SUCCESS;
                }
@@ -323,7 +323,7 @@ static int ldb_msg_el_merge(struct ldb_module *module, struct ldb_message *local
                if (map->u.generate.generate_local == NULL) {
                        ldb_debug(ldb, LDB_DEBUG_ERROR, "ldb_map: "
                                  "Skipping attribute '%s': "
-                                 "'generate_local' not set\n",
+                                 "'generate_local' not set",
                                  attr_name);
                        return LDB_SUCCESS;
                }
@@ -900,7 +900,7 @@ static int map_subtree_collect_remote(struct ldb_module *module, void *mem_ctx,
        if (map->type == MAP_GENERATE) {
                ldb_debug(ldb, LDB_DEBUG_WARNING, "ldb_map: "
                          "Skipping attribute '%s': "
-                         "'convert_operator' not set\n",
+                         "'convert_operator' not set",
                          tree->u.equality.attr);
                *new = NULL;
                return 0;
@@ -1062,7 +1062,7 @@ int map_return_entry(struct map_context *ac, struct ldb_reply *ares)
                           ac->req->op.search.scope)) {
                ldb_debug(ldb, LDB_DEBUG_TRACE, "ldb_map: "
                          "Skipping record '%s': "
-                         "doesn't match original search\n",
+                         "doesn't match original search",
                          ldb_dn_get_linearized(ares->message->dn));
                return LDB_SUCCESS;
        }
index 042c1c928292efd9647b54197f086a0edf27fce0..2c399686eafce1fd563ebf3809603e6d868599d2 100644 (file)
@@ -141,7 +141,7 @@ static int ltdb_attributes_load(struct ldb_module *module)
                const struct ldb_schema_syntax *s;
 
                if (ltdb_attributes_flags(&msg->elements[i], &flags) != 0) {
-                       ldb_debug(ldb, LDB_DEBUG_ERROR, "Invalid @ATTRIBUTES element for '%s'\n", msg->elements[i].name);
+                       ldb_debug(ldb, LDB_DEBUG_ERROR, "Invalid @ATTRIBUTES element for '%s'", msg->elements[i].name);
                        goto failed;
                }
                switch (flags & ~LTDB_FLAG_HIDDEN) {
@@ -156,7 +156,7 @@ static int ltdb_attributes_load(struct ldb_module *module)
                        break;
                default:
                        ldb_debug(ldb, LDB_DEBUG_ERROR, 
-                                 "Invalid flag combination 0x%x for '%s' in @ATTRIBUTES\n",
+                                 "Invalid flag combination 0x%x for '%s' in @ATTRIBUTES",
                                  flags, msg->elements[i].name);
                        goto failed;
                }
@@ -164,7 +164,7 @@ static int ltdb_attributes_load(struct ldb_module *module)
                s = ldb_standard_syntax_by_name(ldb, syntax);
                if (s == NULL) {
                        ldb_debug(ldb, LDB_DEBUG_ERROR, 
-                                 "Invalid attribute syntax '%s' for '%s' in @ATTRIBUTES\n",
+                                 "Invalid attribute syntax '%s' for '%s' in @ATTRIBUTES",
                                  syntax, msg->elements[i].name);
                        goto failed;
                }
index fab60cb1253677a5daf96371a3160864f1c2992b..1daa4500f89b0c6859232d06f27005c0c41104a5 100644 (file)
@@ -1409,7 +1409,7 @@ int ltdb_index_del_value(struct ldb_module *module, const char *dn,
                struct ldb_ldif ldif;
 
                ldb_debug(ldb, LDB_DEBUG_ERROR,
-                               "ERROR: dn %s not found in %s\n", dn,
+                               "ERROR: dn %s not found in %s", dn,
                                ldb_dn_get_linearized(dn_key));
                ldif.changetype = LDB_CHANGETYPE_NONE;
                ldif.msg = msg;
@@ -1587,7 +1587,7 @@ static int re_index(struct tdb_context *tdb, TDB_DATA key, TDB_DATA data, void *
        key2 = ltdb_key(module, msg->dn);
        if (key2.dptr == NULL) {
                /* probably a corrupt record ... darn */
-               ldb_debug(ldb, LDB_DEBUG_ERROR, "Invalid DN in re_index: %s\n",
+               ldb_debug(ldb, LDB_DEBUG_ERROR, "Invalid DN in re_index: %s",
                                                        ldb_dn_get_linearized(msg->dn));
                talloc_free(msg);
                return 0;
@@ -1609,7 +1609,7 @@ static int re_index(struct tdb_context *tdb, TDB_DATA key, TDB_DATA data, void *
                ret = ltdb_index_add0(module, dn, msg->elements, msg->num_elements);
        } else {
                ldb_debug(ldb, LDB_DEBUG_ERROR,
-                       "Adding special ONE LEVEL index failed (%s)!\n",
+                       "Adding special ONE LEVEL index failed (%s)!",
                        ldb_dn_get_linearized(msg->dn));
        }
 
index 1995606f88042a0595db1ba89e59c0a7b9731f7c..5640e7053c8f493ca9e1157d4b51d38aa50d659b 100644 (file)
@@ -280,7 +280,7 @@ int ltdb_unpack_data(struct ldb_module *module,
 
        if (remaining != 0) {
                ldb_debug(ldb, LDB_DEBUG_ERROR, 
-                         "Error: %d bytes unread in ltdb_unpack_data\n", remaining);
+                         "Error: %d bytes unread in ltdb_unpack_data", remaining);
        }
 
        return 0;
index 4a452761b8332de4431c46da1cf01ece145a8f02..d4f7b452cb4c22a1743d103be5b053051d2cd9b3 100644 (file)
@@ -1276,7 +1276,7 @@ static int ltdb_connect(struct ldb_context *ldb, const char *url,
                                   ldb_get_create_perms(ldb), ldb);
        if (!ltdb->tdb) {
                ldb_debug(ldb, LDB_DEBUG_ERROR,
-                         "Unable to open tdb '%s'\n", path);
+                         "Unable to open tdb '%s'", path);
                talloc_free(ltdb);
                return -1;
        }
index dd5afd868cd3fa144b9908f31bae4065a9b46603..271cf5262506d47583996eccfe06062a147dc68e 100644 (file)
@@ -393,7 +393,7 @@ static int asq_init(struct ldb_module *module)
 
        ret = ldb_mod_register_control(module, LDB_CONTROL_ASQ_OID);
        if (ret != LDB_SUCCESS) {
-               ldb_debug(ldb, LDB_DEBUG_WARNING, "asq: Unable to register control with rootdse!\n");
+               ldb_debug(ldb, LDB_DEBUG_WARNING, "asq: Unable to register control with rootdse!");
        }
 
        return ldb_next_init(module);
index 43b223b52e19f078a5adaf483a5123d8352a3e32..77b0014afac35739b91ab46cc19e60672ef59887 100644 (file)
@@ -169,8 +169,8 @@ static int operational_search_post_process(struct ldb_module *module,
        return 0;
 
 failed:
-       ldb_debug_set(ldb, LDB_DEBUG_WARNING, 
-                     "operational_search_post_process failed for attribute '%s'\n", 
+       ldb_debug_set(ldb, LDB_DEBUG_WARNING,
+                     "operational_search_post_process failed for attribute '%s'",
                      attrs[a]);
        return -1;
 }
index f2692305d55918a810626d06117ee8c9599c5cd4..b712f84872154327aeda6bd5a8749fd80d0144d6 100644 (file)
@@ -409,7 +409,7 @@ static int paged_request_init(struct ldb_module *module)
        if (ret != LDB_SUCCESS) {
                ldb_debug(ldb, LDB_DEBUG_WARNING,
                        "paged_results:"
-                       "Unable to register control with rootdse!\n");
+                       "Unable to register control with rootdse!");
        }
 
        return ldb_next_init(module);
index 880678d89de4f576dd808573babdffca2e456724..e9f873f0732e8dfc3124182f6f3945dbc2a3c363 100644 (file)
@@ -98,7 +98,7 @@ static int rdn_name_add(struct ldb_module *module, struct ldb_request *req)
        int i, ret;
 
        ldb = ldb_module_get_ctx(module);
-       ldb_debug(ldb, LDB_DEBUG_TRACE, "rdn_name_add_record\n");
+       ldb_debug(ldb, LDB_DEBUG_TRACE, "rdn_name_add_record");
 
        /* do not manipulate our control entries */
        if (ldb_dn_is_special(req->op.add.message->dn)) {
@@ -288,7 +288,7 @@ static int rdn_name_rename(struct ldb_module *module, struct ldb_request *req)
        int ret;
 
        ldb = ldb_module_get_ctx(module);
-       ldb_debug(ldb, LDB_DEBUG_TRACE, "rdn_name_rename\n");
+       ldb_debug(ldb, LDB_DEBUG_TRACE, "rdn_name_rename");
 
        /* do not manipulate our control entries */
        if (ldb_dn_is_special(req->op.rename.newdn)) {
index a95a86140c4df5071c22436b99266bfbad1f6df3..b4ea017b3269947e70c11ce756f049ba1d933ea7 100644 (file)
@@ -339,7 +339,7 @@ static int server_sort_init(struct ldb_module *module)
        if (ret != LDB_SUCCESS) {
                ldb_debug(ldb, LDB_DEBUG_WARNING,
                        "server_sort:"
-                       "Unable to register control with rootdse!\n");
+                       "Unable to register control with rootdse!");
        }
 
        return ldb_next_init(module);