diff options
author | Tim Potter <tpot@samba.org> | 2005-08-02 20:44:30 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:00:22 -0500 |
commit | 311cf22a2e028d560000da0645abd3625d1cbd3d (patch) | |
tree | 66e4daaaf0152b8ec0b06cb1cf060ab63873d1f6 /source3/lib | |
parent | 191b5977d0c7bf65d418e5e97de0e8b8d9d5237c (diff) | |
download | samba-311cf22a2e028d560000da0645abd3625d1cbd3d.tar.gz samba-311cf22a2e028d560000da0645abd3625d1cbd3d.tar.bz2 samba-311cf22a2e028d560000da0645abd3625d1cbd3d.zip |
r8946: Some casts to fix warnings when time_t is an unsigned type. Fixes
bugzilla #1888 and #1894.
(This used to be commit dcc74371388d280d8ee5130a04e1594ae88d19b3)
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/time.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/lib/time.c b/source3/lib/time.c index f7b0aefe4f..5e0f5646fc 100644 --- a/source3/lib/time.c +++ b/source3/lib/time.c @@ -366,7 +366,7 @@ time_t nt_time_to_unix_abs(NTTIME *nt) return(0); if (nt->high==0x80000000 && nt->low==0) - return -1; + return (time_t)-1; /* reverse the time */ /* it's a negative value, turn it to positive */ @@ -421,7 +421,7 @@ void unix_to_nt_time(NTTIME *nt, time_t t) nt->high = 0x7fffffff; return; } - if (t == -1) { + if (t == (time_t)-1) { nt->low = 0xffffffff; nt->high = 0xffffffff; return; @@ -462,7 +462,7 @@ void unix_to_nt_time_abs(NTTIME *nt, time_t t) return; } - if (t == -1) { + if (t == (time_t)-1) { /* that's what NT uses for infinite */ nt->low = 0x0; nt->high = 0x80000000; |