diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2007-08-12 00:55:03 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:29:30 -0500 |
commit | 594bbfcdeedc306ce4634dd827df342e86ed8390 (patch) | |
tree | 212d5765b8d897f65ecb99f417159a43d379c2c5 /source3/lib/tdb/common/open.c | |
parent | 921fbb25eb4a6097a1e960abadc4dc4b11d32cf6 (diff) | |
download | samba-594bbfcdeedc306ce4634dd827df342e86ed8390.tar.gz samba-594bbfcdeedc306ce4634dd827df342e86ed8390.tar.bz2 samba-594bbfcdeedc306ce4634dd827df342e86ed8390.zip |
r24340: Use standard data type uint32_t rather than tdb-specific u32.
(This used to be commit 26d1430283bd4ae8b8a84f3253e33417d509c1a4)
Diffstat (limited to 'source3/lib/tdb/common/open.c')
-rw-r--r-- | source3/lib/tdb/common/open.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source3/lib/tdb/common/open.c b/source3/lib/tdb/common/open.c index edb0a50916..0bd1c91a5e 100644 --- a/source3/lib/tdb/common/open.c +++ b/source3/lib/tdb/common/open.c @@ -34,8 +34,8 @@ static struct tdb_context *tdbs = NULL; /* This is based on the hash algorithm from gdbm */ static unsigned int default_tdb_hash(TDB_DATA *key) { - u32 value; /* Used to compute the hash value. */ - u32 i; /* Used to cycle through random values. */ + uint32_t value; /* Used to compute the hash value. */ + uint32_t i; /* Used to cycle through random values. */ /* Set the initial value from the key size. */ for (value = 0x238F13AF * key->dsize, i=0; i < key->dsize; i++) @@ -151,7 +151,7 @@ struct tdb_context *tdb_open_ex(const char *name, int hash_size, int tdb_flags, struct stat st; int rev = 0, locked = 0; unsigned char *vp; - u32 vertest; + uint32_t vertest; if (!(tdb = (struct tdb_context *)calloc(1, sizeof *tdb))) { /* Can't log this */ @@ -249,8 +249,8 @@ struct tdb_context *tdb_open_ex(const char *name, int hash_size, int tdb_flags, rev = (tdb->flags & TDB_CONVERT); } vp = (unsigned char *)&tdb->header.version; - vertest = (((u32)vp[0]) << 24) | (((u32)vp[1]) << 16) | - (((u32)vp[2]) << 8) | (u32)vp[3]; + vertest = (((uint32_t)vp[0]) << 24) | (((uint32_t)vp[1]) << 16) | + (((uint32_t)vp[2]) << 8) | (uint32_t)vp[3]; tdb->flags |= (vertest==TDB_VERSION) ? TDB_BIGENDIAN : 0; if (!rev) tdb->flags &= ~TDB_CONVERT; |