summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/cmdline/popt_common.c2
-rw-r--r--source4/lib/events.c2
-rw-r--r--source4/lib/smbpasswd.c8
-rw-r--r--source4/lib/tdb/common/tdbutil.c8
-rw-r--r--source4/lib/time.c12
-rw-r--r--source4/lib/util_str.c4
6 files changed, 18 insertions, 18 deletions
diff --git a/source4/lib/cmdline/popt_common.c b/source4/lib/cmdline/popt_common.c
index 1b8e3bd93e..f659468561 100644
--- a/source4/lib/cmdline/popt_common.c
+++ b/source4/lib/cmdline/popt_common.c
@@ -191,7 +191,7 @@ static void get_credentials_file(const char *file, struct user_auth_info *info)
{
XFILE *auth;
fstring buf;
- uint16 len = 0;
+ uint16_t len = 0;
char *ptr, *val, *param;
if ((auth=x_fopen(file, O_RDONLY, 0)) == NULL)
diff --git a/source4/lib/events.c b/source4/lib/events.c
index 85a2cee70f..50f3f53c94 100644
--- a/source4/lib/events.c
+++ b/source4/lib/events.c
@@ -357,7 +357,7 @@ int event_loop_wait(struct event_context *ev)
which ones and call the handler, being careful to allow
the handler to remove itself when called */
for (fe=ev->fd_events; fe; fe=fe->next) {
- uint16 flags = 0;
+ uint16_t flags = 0;
if (FD_ISSET(fe->fd, &r_fds)) flags |= EVENT_FD_READ;
if (FD_ISSET(fe->fd, &w_fds)) flags |= EVENT_FD_WRITE;
if (fe->ref_count && flags) {
diff --git a/source4/lib/smbpasswd.c b/source4/lib/smbpasswd.c
index 92ae1ffea2..5cb8439878 100644
--- a/source4/lib/smbpasswd.c
+++ b/source4/lib/smbpasswd.c
@@ -88,7 +88,7 @@ BOOL smbpasswd_gethexpwd(char *p, unsigned char *pwd)
/*! Convert a 16-byte array into 32 hex characters. */
-void smbpasswd_sethexpwd(fstring p, unsigned char *pwd, uint16 acb_info)
+void smbpasswd_sethexpwd(fstring p, unsigned char *pwd, uint16_t acb_info)
{
if (pwd != NULL) {
int i;
@@ -104,9 +104,9 @@ void smbpasswd_sethexpwd(fstring p, unsigned char *pwd, uint16 acb_info)
/*! Decode the account control bits (ACB) info from a string. */
-uint16 smbpasswd_decode_acb_info(const char *p)
+uint16_t smbpasswd_decode_acb_info(const char *p)
{
- uint16 acb_info = 0;
+ uint16_t acb_info = 0;
BOOL finished = False;
/*
@@ -170,7 +170,7 @@ uint16 smbpasswd_decode_acb_info(const char *p)
/*! Encode account control bits (ACBs) into a string. */
-char *smbpasswd_encode_acb_info(uint16 acb_info)
+char *smbpasswd_encode_acb_info(uint16_t acb_info)
{
static fstring acct_str;
size_t i = 0;
diff --git a/source4/lib/tdb/common/tdbutil.c b/source4/lib/tdb/common/tdbutil.c
index bdb8621d16..3fe3ff4b11 100644
--- a/source4/lib/tdb/common/tdbutil.c
+++ b/source4/lib/tdb/common/tdbutil.c
@@ -428,7 +428,7 @@ size_t tdb_pack(TDB_CONTEXT *tdb, char *buf, int bufsize, const char *fmt, ...)
{
va_list ap;
uint8 bt;
- uint16 w;
+ uint16_t w;
uint32_t d;
int i;
void *p;
@@ -451,7 +451,7 @@ size_t tdb_pack(TDB_CONTEXT *tdb, char *buf, int bufsize, const char *fmt, ...)
break;
case 'w': /* unsigned 16-bit integer */
len = 2;
- w = (uint16)va_arg(ap, int);
+ w = (uint16_t)va_arg(ap, int);
if (bufsize && bufsize >= len)
SSVAL(buf, 0, w);
break;
@@ -522,7 +522,7 @@ int tdb_unpack(TDB_CONTEXT *tdb, char *buf, int bufsize, const char *fmt, ...)
{
va_list ap;
uint8 *bt;
- uint16 *w;
+ uint16_t *w;
uint32_t *d;
int len;
int *i;
@@ -546,7 +546,7 @@ int tdb_unpack(TDB_CONTEXT *tdb, char *buf, int bufsize, const char *fmt, ...)
break;
case 'w':
len = 2;
- w = va_arg(ap, uint16 *);
+ w = va_arg(ap, uint16_t *);
if (bufsize < len)
goto no_space;
*w = SVAL(buf, 0);
diff --git a/source4/lib/time.c b/source4/lib/time.c
index 99738d5a4a..1f95ef7daf 100644
--- a/source4/lib/time.c
+++ b/source4/lib/time.c
@@ -141,9 +141,9 @@ BOOL null_mtime(time_t mtime)
/*******************************************************************
create a 16 bit dos packed date
********************************************************************/
-static uint16 make_dos_date1(struct tm *t)
+static uint16_t make_dos_date1(struct tm *t)
{
- uint16 ret=0;
+ uint16_t ret=0;
ret = (((unsigned)(t->tm_mon+1)) >> 3) | ((t->tm_year-80) << 1);
ret = ((ret&0xFF)<<8) | (t->tm_mday | (((t->tm_mon+1) & 0x7) << 5));
return ret;
@@ -152,9 +152,9 @@ static uint16 make_dos_date1(struct tm *t)
/*******************************************************************
create a 16 bit dos packed time
********************************************************************/
-static uint16 make_dos_time1(struct tm *t)
+static uint16_t make_dos_time1(struct tm *t)
{
- uint16 ret=0;
+ uint16_t ret=0;
ret = ((((unsigned)t->tm_min >> 3)&0x7) | (((unsigned)t->tm_hour) << 3));
ret = ((ret&0xFF)<<8) | ((t->tm_sec/2) | ((t->tm_min & 0x7) << 5));
return ret;
@@ -382,7 +382,7 @@ const char *nt_time_string(TALLOC_CTX *mem_ctx, NTTIME nt)
/*
put a NTTIME into a packet
*/
-void push_nttime(void *base, uint16 offset, NTTIME t)
+void push_nttime(void *base, uint16_t offset, NTTIME t)
{
SBVAL(base, offset, t);
}
@@ -390,7 +390,7 @@ void push_nttime(void *base, uint16 offset, NTTIME t)
/*
pull a NTTIME from a packet
*/
-NTTIME pull_nttime(void *base, uint16 offset)
+NTTIME pull_nttime(void *base, uint16_t offset)
{
NTTIME ret = BVAL(base, offset);
return ret;
diff --git a/source4/lib/util_str.c b/source4/lib/util_str.c
index 7d6505bab2..4002c21e9a 100644
--- a/source4/lib/util_str.c
+++ b/source4/lib/util_str.c
@@ -86,7 +86,7 @@ BOOL next_token_nr(const char **ptr, char *buff, const char *sep, size_t bufsize
return ret;
}
-static uint16 tmpbuf[sizeof(pstring)];
+static uint16_t tmpbuf[sizeof(pstring)];
/**
Convert list of tokens to array; dependent on above routine.
@@ -269,7 +269,7 @@ void string_replace(char *s,char oldc,char newc)
size_t str_charnum(const char *s)
{
- uint16 tmpbuf2[sizeof(pstring)];
+ uint16_t tmpbuf2[sizeof(pstring)];
push_ucs2(NULL, tmpbuf2,s, sizeof(tmpbuf2), STR_TERMINATE);
return strlen_w(tmpbuf2);
}