summaryrefslogtreecommitdiff
path: root/source4/lib/ldb/tools/ldbadd.c
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2009-11-06 18:35:17 +0100
committerMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-03-06 11:35:17 +0100
commite10fa46f3e5b3481e3c95e52f9d666eafd50ed25 (patch)
tree53637c911edbbf5fb5c16a42cb1816c3315ec6cc /source4/lib/ldb/tools/ldbadd.c
parent24049e8fc58c5216b3af8fdaf327471eaff882a1 (diff)
downloadsamba-e10fa46f3e5b3481e3c95e52f9d666eafd50ed25.tar.gz
samba-e10fa46f3e5b3481e3c95e52f9d666eafd50ed25.tar.bz2
samba-e10fa46f3e5b3481e3c95e52f9d666eafd50ed25.zip
LDB:tools - change counters to be unsigned
In most cases we do count LDB objects which are enumerated within the "unsigned" type. Therefore no need to use "signed" counters.
Diffstat (limited to 'source4/lib/ldb/tools/ldbadd.c')
-rw-r--r--source4/lib/ldb/tools/ldbadd.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source4/lib/ldb/tools/ldbadd.c b/source4/lib/ldb/tools/ldbadd.c
index e618ab52f7..0dd35cc1b3 100644
--- a/source4/lib/ldb/tools/ldbadd.c
+++ b/source4/lib/ldb/tools/ldbadd.c
@@ -35,7 +35,7 @@
#include "tools/cmdline.h"
#include "ldbutil.h"
-static int failures;
+static unsigned int failures;
static struct ldb_cmdline *options;
static void usage(void)
@@ -50,7 +50,7 @@ static void usage(void)
/*
add records from an opened file
*/
-static int process_file(struct ldb_context *ldb, FILE *f, int *count)
+static int process_file(struct ldb_context *ldb, FILE *f, unsigned int *count)
{
struct ldb_ldif *ldif;
int ret = LDB_SUCCESS;
@@ -93,7 +93,8 @@ static int process_file(struct ldb_context *ldb, FILE *f, int *count)
int main(int argc, const char **argv)
{
struct ldb_context *ldb;
- int i, ret=0, count=0;
+ unsigned int i, count = 0;
+ int ret=0;
ldb = ldb_init(NULL, NULL);