s4-ldbmodify: show the error code as well as error string
authorAndrew Tridgell <tridge@samba.org>
Tue, 29 Dec 2009 00:39:29 +0000 (11:39 +1100)
committerAndrew Tridgell <tridge@samba.org>
Fri, 1 Jan 2010 21:16:55 +0000 (08:16 +1100)
source4/lib/ldb/tools/ldbmodify.c

index 575658600cfdb81a6fbddccf6404def131b033a4..57988cbb308e8ed99e1124af34e1545e9b3a828c 100644 (file)
@@ -73,7 +73,8 @@ static int process_file(struct ldb_context *ldb, FILE *f, int *count)
                        break;
                }
                if (ret != LDB_SUCCESS) {
-                       fprintf(stderr, "ERR: \"%s\" on DN %s\n", 
+                       fprintf(stderr, "ERR: (%s) \"%s\" on DN %s\n",
+                               ldb_strerror(ret),
                                ldb_errstring(ldb), ldb_dn_get_linearized(ldif->msg->dn));
                        failures++;
                } else {