r9992: More fixes from the 64-bit warning police.
authorTim Potter <tpot@samba.org>
Sat, 3 Sep 2005 12:35:50 +0000 (12:35 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:36:27 +0000 (13:36 -0500)
source/dsdb/samdb/ldb_modules/samba3sam.c

index 0ee04330715cbdfea218e72772b62a23267e1693..a68f6f0640586f45fbd78fdfed7d646518466448 100644 (file)
@@ -157,7 +157,7 @@ static struct ldb_val lookup_gid(struct ldb_module *module, TALLOC_CTX *ctx, con
                return *talloc_zero(ctx, struct ldb_val);
        }
 
-       retval.data = (uint8_t *)talloc_asprintf(ctx, "%d", pwd->pw_gid);
+       retval.data = (uint8_t *)talloc_asprintf(ctx, "%ld", (unsigned long)pwd->pw_gid);
        retval.length = strlen((char *)retval.data);
 
        return retval;
@@ -174,7 +174,7 @@ static struct ldb_val lookup_uid(struct ldb_module *module, TALLOC_CTX *ctx, con
                return *talloc_zero(ctx, struct ldb_val);
        }
 
-       retval.data = (uint8_t *)talloc_asprintf(ctx, "%d", pwd->pw_uid);
+       retval.data = (uint8_t *)talloc_asprintf(ctx, "%ld", (unsigned long)pwd->pw_uid);
        retval.length = strlen((char *)retval.data);
 
        return retval;