summaryrefslogtreecommitdiffstats
path: root/source/lib/time.c
Commit message (Collapse)AuthorAgeFilesLines
* More signed/unsigned fixes (yes, I run with funny compiler options) andAndrew Bartlett2003-02-221-1/+1
| | | | | | make x_fwrite() match fwrite() in returning a size_t. Andrew Bartlett
* The _abs time functions should not be converting from/to GMT.Jeremy Allison2002-12-101-18/+11
| | | | | Patch from "Jordan Russell" <jr-list-samba-technical@quo.to> Jeremy.
* Patch from "Stefan (metze) Metzmacher" <metze@metzemix.de> to do a *much*Andrew Bartlett2002-09-261-2/+12
| | | | | | | | | | | | better job of working with usrmgr. Previously we were blanking out entires, and all sort of mischif. The new patch (which I've now had a chance to test/modify) also takes care not to expand % values (ie we go \\%L\%U -> \\server\user, we don't want to store \\server\user back) and to correctly notice 'not set' compared to 'null string' etc. Andrew Bartlett
* based on function prototype, the args were switched - this gave an errorHerb Lewis2002-08-301-1/+1
| | | | | on the IRIX compiler. could whoever put the FIXME message take a look and see if it is still broken.
* Put in intermediate version of new SAM system. It's not stable yet, codeJelmer Vernooij2002-08-281-0/+6
| | | | | | | | | might be ugly, etc - please don't blame me for anything but instead try to fix the code :-). Compiling of the new sam system can be enabled with the configure option --with-sam Removing passdb/passgrp.c as it's unused fix typo in utils/testparm.c
* used findstatic.pl to make some variables static and remove some deadAndrew Tridgell2002-07-011-5/+0
| | | | code
* merge from SAMBA_2_2Gerald Carter2002-05-201-1/+1
|
* Removed version number from file header.Tim Potter2002-01-301-2/+1
| | | | Changed "SMB/Netbios" to "SMB/CIFS" in file header.
* Round and round we go....Jeremy Allison2002-01-111-1/+2
| | | | Jeremy.
* Latest attempt at changeid.Jeremy Allison2002-01-111-2/+26
| | | | Jeremy.
* added a tdb to store the account policy informations.Jean-François Micouleau2001-12-031-0/+88
| | | | | | | | | | | | | | You can change them with either usermanager->policies->account or from a command prompt on NT/W2K: net accounts /domain we can add a rpc accounts to the net command. As the net_rpc.c is still empty, I did not start. How should I add command to it ? Should I take the rpcclient/cmd_xxx functions and call them from there ? alse changed the SAM_UNK_INFO_3 parser, it's an NTTIME. This one is more for jeremy ;-) J.F.
* Removed TimeInit() call from every client program (except for one placeTim Potter2001-11-231-12/+26
| | | | | in smbd/process.c where the timezone is reinitialised. Was replaced with check for a static is_initialised boolean.
* Fixed the bug with member servers in a Samba PDC hosted domain not allowingJeremy Allison2001-10-021-0/+18
| | | | | | other access. Problem was max time was being set to 0xffffffff, instead of 0x7fffffff. Jeremy.
* Removed 'extern int DEBUGLEVEL' as it is now in the smb.h header.Tim Potter2001-10-021-2/+0
|
* move to SAFE_FREE()Simo Sorce2001-09-171-1/+1
|
* Merge from TNG - function to initialise NTTIME structure.Tim Potter2001-08-281-0/+9
|
* this is a big global fix for the ptr = Realloc(ptr, size) bug.Simo Sorce2001-08-121-3/+6
| | | | | | many possible mem leaks, and segfaults fixed. someone should port this fix to 2.2 also.
* Another large patch for the passdb rewrite.Gerald Carter2000-11-211-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | o added BOOL own_memory flag in SAM_ACCOUNT so we could use static memory for string pointer assignment or allocate a new string o added a reference TDB passdb backend. This is only a reference and should not be used in production because - RID's are generated using the same algorithm as with smbpasswd - a TDB can only have one key (w/o getting into problems) and we need three. Therefore the pdb_sam-getpwuid() and pdb_getsampwrid() functions are interative searches :-( we need transaction support, multiple indexes, and a nice open source DBM. The Berkeley DB (from sleepycat.com seems to fit this criteria now) o added a new parameter "private dir" as many places in the code were using lp_smb_passwd_file() and chopping off the filename part. This makes more sense to me and I will docuement it in the man pages o Ran through Insure-lite and corrected memory leaks. Need for a public flogging this time Jeremy (-: -- jerry
* acconfig.h configure configure.in: Added check for UT_SYSLEN for utmp code.Jeremy Allison2000-03-221-1/+1
| | | | | | | | | | | | | | include/byteorder.h: Added alignment macros. include/nameserv.h: Added defines for msg_type field options - from rfc1002. lib/time.c: Typo fix. lib/util_unistr.c: Updates from UNICODE branch. printing/nt_printing.c: bzero -> memset. smbd/connection.c: Added check for UT_SYSLEN for utmp code. Other fixes : Rollback of unapproved commit from Luke. Please *ask* next time before doing large changes to HEAD. Jeremy.
* Fix from NAKAJI Hiroyuki for a trailing '\n\ in asctime.Jeremy Allison2000-03-151-0/+2
| | | | Jeremy.
* first pass at updating head branch to be to be the same as the SAMBA_2_0 branchAndrew Tridgell1999-12-131-17/+51
|
* const feeding frenzyLuke Leighton1999-11-081-1/+1
|
* Added init_nt_time function which initialises an NTTIME to -1.Matthew Chapman1999-02-011-7/+9
|
* rpcclient registry commands.Luke Leighton1998-11-101-37/+42
|
* remove unused arguments from some static functions.Andrew Tridgell1998-10-061-4/+4
|
* Changes to test in configure if capabilities are enabled on a system.Jeremy Allison1998-09-281-1/+1
| | | | | | | | | | Changes to get Samba to compile cleanly with the IRIX compiler with the options : -fullwarn -woff 1209,1174 (the -woff options are to turn off warnings about unused function parameters and controlling loop expressions being constants). Split prototype generation as we hit a limit in IRIX nawk. Removed "." code in smbd/filename.c (yet again :-). Jeremy.
* added in samr commands. assistance in returning the missing functions,Luke Leighton1998-09-251-0/+12
| | | | automatically removed because they were "unused", would be appreciated.
* More abstraction of file system data types, to move to a 64Jeremy Allison1998-09-011-1/+1
| | | | | | | | | | | | | | | | | | | | | bit file interface for the NT SMB's. Created a new define, SMB_STRUCT_STAT that currently is defined to be struct stat - this wil change to a user defined type containing 64 bit info when the correct wrappers are written for 64 bit stat(), fstat() and lstat() calls. Also changed all sys_xxxx() calls that were previously just wrappers to the same call prefixed by a dos_to_unix() call into dos_xxxx() calls. This makes it explicit when a pathname translation is being done, and when it is not. Now, all sys_xxx() calls are meant to be wrappers to mask OS differences, and not silently converting filenames on the fly. Jeremy.
* merge from the autoconf2 branch to the main branchAndrew Tridgell1998-07-291-29/+18
|
* nttrans.c: More code towards NT protocol.Jeremy Allison1998-06-301-2/+6
| | | | | | smb.h: More code towards NT protocol. time.c: Fix for sco bug. Jeremy.
* Added Paul Eggerts LocalTime patch.Jeremy Allison1998-05-291-8/+28
| | | | Jeremy.
* This is a security audit change of the main source.Jeremy Allison1998-05-121-1/+1
| | | | | | | | | | | | | | | | | | It removed all ocurrences of the following functions : sprintf strcpy strcat The replacements are slprintf, safe_strcpy and safe_strcat. It should not be possible to use code in Samba that uses sprintf, strcpy or strcat, only the safe_equivalents. Once Andrew has fixed the slprintf implementation then this code will be moved back to the 1.9.18 code stream. Jeremy.
* Patch from Chris Maltby <chris@softway.com.au>. His comments follow:Jeremy Allison1998-04-021-4/+4
| | | | | | | | | | | | | | + improvement to smbtar to allow exclusion/inclusion of system and hidden files, and to generate a listing of what has been archived in a format useful for automated backup systems. + add the "Softq" spooling system to samba's printing capabilities. + I have "fixed" the intrusion of US style dates into samba reporting as well. The format yyyy/mm/dd is not only uunambiguous, but also has the benefit of making lexicographic sorts work correctly. Jeremy.
* Adding the same change as was added to 1.9.18 branch to add theJeremy Allison1998-03-161-3/+8
| | | | | | | | | | | | | | | | | | | | | | | "name resolve order" parameter. source/Makefile: Re-ordered link for name resolve order code. source/clientgen.c: source/clientutil.c: Added calls to resolve_name(). source/includes.h: Added HPUX zombie fix. source/loadparm.c: Added new name resolve order parameter. source/namequery.c: Re-wrote to include parsing of lmhosts file, new resolve_name() function requested by John. source/nmbd.c: Tell resolve_name not to do WINS lookups if we are the WINS server. source/nmbd_lmhosts.c: Call lmhosts parsing functions in namequery.c source/password.c: Call resolve_name() to lookup security=server name. source/reply.c: source/time.c: source/trans2.c: "fake directory create times" fix from Jim Hague - hague@research.canon.com.au. source/util.c: Removed isalnum() test in Get_Hostname() that seems to cause problems on many systems. Jeremy.
* added Date and Expires headers in the mini web server so clients knowAndrew Tridgell1998-03-101-0/+15
| | | | what they can cache.
* Ding-dong the witch is dead, the witch is dead......Jeremy Allison1998-02-131-14/+0
| | | | | | | | | | | | | | This is the checkin that fixes the infamous Visual C++ 'file has changed' bug. I feel *SO* good about that :-). charset.c: Added (void) to fix Herb's fussy compiler. loadparm.c: Removed "win95 bug compatibility" (didn't like it much anyway :-). Added "dos filetime resolution" instead. reply.c: Added the 2 second timestamp resolution fix that the song above is about. time.c: Removed unneeded get_access_time() function. trans2.c : Removed unneeded "win95 bug compatibility" code. Jeremy.
* Makefile: Added AIX 3.2.5.Jeremy Allison1998-02-111-1/+4
| | | | | | | | | | | | | | | | loadparm.c: Added "win95 bug compatibility" parameter. local.h: Replaced MAX_OPEN_FILES back to 100 from 10 (oops). reply.c: Fixed ulogoff check against uid - changed to vuid. server.c: Changed file struct save of uid - changed to vuid. smb.h: Changed id in struct current_user to vuid. Changed file struct uid to vuid. time.c: Added "win95 bug compatibility" atime -> mtime return. trans2.c: Added "win95 bug compatibility" fixes. uid.c: Changed id in struct current_user to vuid - added checks to set/reset it. util.c: Added code to expand environment variables. version.h : still at 1.9.18 (head branch doesn't matter too much at present). Jeremy.
* A small raft of changes, I will sync up with 1.9.18 also.Jeremy Allison1998-02-071-0/+11
| | | | | | | | | | | | | | | | | chgpasswd.c: Fixed typo in debug message. includes.h: Fix include for aix. kanji.c: Added cap_to_sj as inverse of sj_to_cap. loadparm.c: local.h: password.c: Added code for "networkstation user login" parameter. - patch from Rob Nielsen <ran@adc.com>. printing.c: Added further aix printing fixes. reply.c: Changed access time fetch to a function. trans2.c: Changed access time fetch to a function. time.c: Changed access time fetch to a function. server.c: Made NT redirector workaround final. util.c: Added debug for write_socket failing. Jeremy.
* Added get_create_time() function to time.c.Jeremy Allison1998-01-241-0/+19
| | | | | | | This gets the minimum timestamp associated with a file. reply.c and trans2.c then return this as the create time. Designed to fix problems with VC++ and others. Jeremy.
* This is *not* a big change (although it looks like one).Jeremy Allison1998-01-221-1/+1
| | | | | | | This is merely updating the Copyright statements from 1997 to 1998. It's a once a year thing :-). NO OTHER CHANGES WERE MADE. Jeremy.
* add a warning if the timezone is not a multiple of 1 minute. ThisAndrew Tridgell1997-12-031-0/+5
| | | | should catch broken timezone files in slackware linux.
* use LocTimeDiff() not TimeDiff() to ensure that longdate conversion isAndrew Tridgell1997-11-211-1/+2
| | | | consistent (this is really just a cosmetic change)
* change from %D to %m/%d/%Y in timestring(). This doesn't really matterAndrew Tridgell1997-11-061-4/+4
| | | | | | as it is only for logging but it will prevent people from writing in to say that we are not y2k compliant after running auto-diagnostic tests.
* loadparm.c: Changed 'interfaces only' parameter to 'bind interfaces only'. AddedJeremy Allison1997-10-201-20/+1
| | | | | | | | | | | | | 'dos filetimes' parameter for UTIME fix. locking_shm.c: Fixed typo (sorry Andrew :-). namepacket.c: Changed lp_interfaces_only() to lp_bind_interfaces_only(). proto.h: The usual. reply.c: Made filetime calls use new file_utime call (wrapper for sys_utime). server.c: Made filetime calls use new file_utime call (wrapper for sys_utime). system.c: Added Andrew's sanity checks to times in sys_utime(). time.c: Moved set_filetime() to server.c. Made null_mtime() global. trans2.c: Made filetime calls use new file_utime call (wrapper for sys_utime). Jeremy (jallison@whistle.com)
* Adding Andrews buffer overflow fixes into the main branch.Jeremy Allison1997-09-261-2/+2
| | | | Jeremy (jallison@whistle.com)
* 'The mother of all checkins' :-). Jeremy Allison (jallison@whistle.com)Samba Release Account1997-05-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Wed May 7 1997: Update for 1.9.17alpha1 release - 'browsefix release' designed to make browsing across subnets work. byteorder.h: Updated copyright to 1997. charcnv.c: Updated copyright to 1997. charset.c Updated copyright to 1997. charset.h Updated copyright to 1997. client.c Updated copyright to 1997. clientutil.c Updated copyright to 1997. dir.c Updated copyright to 1997. fault.c Updated copyright to 1997. includes.h Updated copyright to 1997. interface.c Updated copyright to 1997. ipc.c Updated copyright to 1997. kanji.c Updated copyright to 1997. kanji.h Updated copyright to 1997. loadparm.c Updated copyright to 1997. locking.c Updated copyright to 1997. mangle.c Updated copyright to 1997. message.c Updated copyright to 1997. nameannounce.c Made use of WINS subnet explicit. Added reset_announce_timer() so announcement can be made immediately when we become a master. Expanded code to do sync with dmb. namebrowse.c Removed redundent checks for AM_MASTER in sync code. Made use of WINS subnet explicit. namedbname.c Made use of WINS subnet explicit. namedbresp.c Made use of WINS subnet explicit. namedbserver.c Made use of WINS subnet explicit. namedbsubnet.c Explicitly add workgroup to WINS subnet when we become a dmb. Made use of WINS subnet explicit. namedbwork.c Made use of WINS subnet explicit. Removed redundent check_work_servertype() function. nameelect.c Explicitly add workgroup to WINS subnet when we become a master browser. Made use of WINS subnet explicit. namelogon.c Updated copyright to 1997. namepacket.c Updated copyright to 1997. namequery.c Updated copyright to 1997. nameresp.c Made use of WINS subnet explicit. Made nmbd fail if configured as master browser and one exists already. nameserv.c Made use of WINS subnet explicit. Remove redundent logon server and domain master code. nameserv.h Add emumerate subnet macros. nameservreply.c Made use of WINS subnet explicit. nameservresp.c Updated copyright to 1997. namework.c Made use of WINS subnet explicit. Updated code to add sync browser entries to add subnet parameter. nmbd.c Added sanity check for misconfigured nmbd. nmblib.c Updated copyright to 1997. nmblookup.c Updated copyright to 1997. nmbsync.c Removed redundent AM_ANY_MASTER check. params.c Updated copyright to 1997. password.c Updated copyright to 1997. pipes.c Updated copyright to 1997. predict.c Updated copyright to 1997. printing.c Updated copyright to 1997. proto.h Changed protos for new nmbd code. quotas.c Updated copyright to 1997. replace.c Updated copyright to 1997. reply.c Updated copyright to 1997. server.c Updated copyright to 1997. shmem.c Updated copyright to 1997. smb.h Updated copyright to 1997. smbencrypt.c Updated copyright to 1997. smbpasswd.c Updated copyright to 1997. smbrun.c Updated copyright to 1997. status.c Updated copyright to 1997. system.c Updated copyright to 1997. testparm.c Updated copyright to 1997. testprns.c Updated copyright to 1997. time.c Updated copyright to 1997. trans2.c Updated copyright to 1997. trans2.h Updated copyright to 1997. uid.c Updated copyright to 1997. username.c Updated copyright to 1997. util.c Updated copyright to 1997. version.h Changed to 1.9.17alpha1.
* Fix fro signed/unsigned problem with TIME_T_MIN from Anatoly V. GrabarSamba Release Account1997-03-071-1/+1
| | | | | <agra@sice.ru> jra@cygnus.com
* - added interface.c and removed all the references to myip, bcast_ipAndrew Tridgell1996-06-061-4/+4
| | | | | | | | | | | | | | | and Netmask, instead replacing them with calls to routines in interface.c - got rid of old MAXINT define - added code to ensure we only return one entry for each name in the ipc enum routines - added new_only option to add_netbios_entry() to prevent overwriting of important names - minor time handling fixup
* Lots of changes!Andrew Tridgell1996-05-311-0/+495
- add faq info on NT printer handling - add "delete readonly" option to help rcs users - add stuff to man pages on new printer options - add "proxy name resolution" option - add "command string" -c option to smbclient (thanks Ken) - split time functions into time.c - rearrange the quotas stuff a bit and fix some bugs - complete rehash of the time handling code thanks to Paul Eggert - fix nmblookup output a bit - add plp print queue parsing from Bertrand Wallrich