From: Volker Lendecke Date: Thu, 19 May 2022 18:10:52 +0000 (+0200) Subject: registry3: Align some integer types X-Git-Tag: talloc-2.3.4~93 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=78ebd8af885841a39eece623623a7807a83903c4;p=thirdparty%2Fsamba.git registry3: Align some integer types Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/source3/registry/reg_backend_db.c b/source3/registry/reg_backend_db.c index b1f6425d56a..829b82d9059 100644 --- a/source3/registry/reg_backend_db.c +++ b/source3/registry/reg_backend_db.c @@ -1045,7 +1045,7 @@ static WERROR regdb_store_keys_internal2(struct db_context *db, { TDB_DATA dbuf; uint8_t *buffer = NULL; - int i = 0; + uint32_t i = 0; uint32_t len, buflen; uint32_t num_subkeys = regsubkey_ctr_numkeys(ctr); char *keyname = NULL; @@ -1739,7 +1739,7 @@ static WERROR regdb_fetch_keys_internal(struct db_context *db, const char *key, uint32_t num_items; uint8_t *buf; uint32_t buflen, len; - int i; + uint32_t i; fstring subkeyname; TALLOC_CTX *frame = talloc_stackframe(); TDB_DATA value; @@ -1854,7 +1854,7 @@ static int regdb_unpack_values(struct regval_ctr *values, uint32_t size; uint8_t *data_p; uint32_t num_values = 0; - int i; + uint32_t i; /* loop and unpack the rest of the registry values */ diff --git a/source3/registry/reg_parse.c b/source3/registry/reg_parse.c index 6230b000c3b..dc084dc51b7 100644 --- a/source3/registry/reg_parse.c +++ b/source3/registry/reg_parse.c @@ -641,7 +641,7 @@ static bool lookslike_utf16(const char* line, size_t len, bool* little_endian) size_t l = MIN(len/2, 64); const uint16_t* u = (const uint16_t*)line; - int i; + size_t i; assert(len >= 2); @@ -667,7 +667,7 @@ static bool lookslike_utf16(const char* line, size_t len, bool* little_endian) static bool lookslike_dos(const char* line, size_t len) { - int i; + size_t i; for (i=0; i