1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-15 23:24:37 +03:00

29 Commits

Author SHA1 Message Date
Gerald Carter
a834a73e34 sync'ing up for 3.0alpha20 release
(This used to be commit 65e7b5273bb58802bf0c389b77f7fcae0a1f6139)
2002-09-25 15:19:00 +00:00
Andrew Tridgell
e90b652848 updated the 3.0 branch from the head branch - ready for alpha18
(This used to be commit 03ac082dcb375b6f3ca3d810a6a6367542bc23ce)
2002-07-15 10:35:28 +00:00
Tim Potter
cd68afe312 Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
(This used to be commit 6a58c9bd06d0d7502a24bf5ce5a2faf0a146edfa)
2002-01-30 06:08:46 +00:00
Jeremy Allison
dd324a5357 Tidyups to remove warnings on tdb standalone code.
Jeremy.
(This used to be commit b03aaddcf35dee93556013eaac9d99bc0f22256a)
2001-12-11 08:24:36 +00:00
Tim Potter
aeb734a8fa Formatting fixup.
(This used to be commit d902baf70970f0358e825cd520b1794fd46465f0)
2001-12-10 04:59:17 +00:00
Martin Pool
858f1865df Fix headers. This I know is correct.
(This used to be commit 0c22a10d738041b3dc0c92d8ea060a86de769563)
2001-12-04 12:44:10 +00:00
Martin Pool
84503c81f0 undo
(This used to be commit fc176f15f27686049453552219b56b9de33ceffa)
2001-12-04 11:41:12 +00:00
Martin Pool
28e676d9c3 Implement suggestion from tridge to leave the old tdb_open interface
as it was, and add tdb_open_ex() which takes a log callback.  I guess
this makes more sense since it's a public interface.
(This used to be commit 391a65395e6cdc0300f81eb1072a3366cacd1203)
2001-12-04 11:25:44 +00:00
Martin Pool
7d9e09f527 Better error handling:
- tdb_open api changed so that you now pass an error handling
   callback when opening the file, so that errors detected during
   opening have somewhere to go.  (All calls from the body of Samba to
   this function go through a wrapper in tdbutil, which has been
   updated.)

 - Clean up logic for deciding how to open tdb.  Emit log messages if
   something goes wrong (e.g. bad magic.)

 - tdbtool now logs errors to stderr.
(This used to be commit 0aa800618eab1043d802c04fb1d125cd07936769)
2001-12-04 07:40:25 +00:00
Tim Potter
25ea74978f Don't display any data if tdb_fetch() failed in the tdbtool "fetch"
command.
(This used to be commit a1cf70ab65058258e56ffcff5b28087b29425b1c)
2001-12-03 04:15:26 +00:00
Tim Potter
3171064521 Updated definition of fstring.
print_asc(): Don't try to print a trailing NULL character
print_key(), print_rec(): Display key in ASCII
(This used to be commit 303b3a35951211775a4e87bcca47cc21236aa422)
2001-12-03 00:23:14 +00:00
Tim Potter
d0ea72d0b7 Added a 'keys' command to tdbtool which prints out all keys in the tdb.
(This used to be commit 1d2305c233ef40ccb016688f918e34392d1a691e)
2001-11-28 03:58:33 +00:00
Tim Potter
e91226daea Removed #ifdef TDB_DEBUG around tdb_dump_all() and tdb_printfreelist()
so that tdbtool can be compiled without having to make clean.
(This used to be commit dad688d8c6b3c98173a846ad833599a4016d2e1a)
2001-11-09 01:26:13 +00:00
Tim Potter
ef67997d0f Patch for having spaces in tdb keys, NULL termination fixes and other
stuff.  From Andrew Esh <AEsh@tricord.com>
(This used to be commit 78207d0fc8c4641fbd8f63f469c4135357edfad8)
2001-08-07 23:21:45 +00:00
Volker Lendecke
efe1d83dbb Print an error message if database could not be opened.
Volker
(This used to be commit b4f06c3ecf8af60352bc9e3af9c35c00827faad2)
2001-08-04 18:17:30 +00:00
Andrew Tridgell
6315ea80fc added list function to tdbtool
(This used to be commit c20838c6358f02dea7967e28a5f23db70ff464f9)
2001-05-30 06:22:10 +00:00
Jeremy Allison
da20d4e5df It compiles for me now :-). rpc_server/srv_lsa.c - added fix to allow w2k
clients to join a Samba domain - odd or even domain name length. Needs more testing.
Jeremy.
(This used to be commit 408672d38261e34cc3714200617b35464d88f931)
2001-02-13 16:28:48 +00:00
David O'Neill
2506c61ab3 Changes from APPLIANCE_HEAD:
source/include/proto.h
        - make proto

    source/printing/nt_printing.c
    source/rpc_server/srv_spoolss_nt.c
        - Fix for the overwriting of printerdata entries when WinNT and
          Win2k are modifying printer parameters on PCL printers. Turns out
          that Win2k creates a printer with a NULL devmode entry and then
          expects to set it on *OPEN* (yes this is insane). So we cannot
          return a "default" devmode for a printer - and we must allow an
          open to set it.

    source/tdb/tdb.c
        - Show freelist in an easier format. Show total free.
        - When storing a new record, allocate memory for the key + data
          before the tdb_allocate() as if the malloc fails a (sparse) hole
          is left in the tdb.

    source/tdb/tdbtool.c
        - Show freelist in an easier format. Show total free.

    source/tdb/Makefile
        - cleaned up Makefile dependancies

    source/smbd/lanman.c
        -  Fix for Win9x corrupting it's own parameter string.

    source/printing/printfsp.c
    source/printing/printing.c
    source/rpc_server/srv_spoolss_nt.c
    source/smbd/close.c
        - Added normal close parameter into print_fsp_end() which treats an
          abnormal close as error condition and deletes the spool file.
(This used to be commit 025f7a092ad258ff774e3f5e53737f8210cc8af6)
2001-01-29 21:34:08 +00:00
Jeremy Allison
0d658c35eb Fixed bug with tdb_next_lock failing when reaching then end of a hashchain
and the next hashchain is empty.
Jeremy
(This used to be commit f3b5e2a172a777e1c3bbf6ac72fe5c7cdb8324b3)
2000-12-07 17:46:11 +00:00
Jeremy Allison
040de369b2 Added print_freelist command.
Jeremy.
(This used to be commit ee89ca9e68abb23fc26cd1378e02e56d0d725e55)
2000-12-02 01:04:11 +00:00
Jeremy Allison
a6f31d6877 Fixes from Damian at Cisco to tidy up some tdbtool issues.
Jeremy.
(This used to be commit 623bfa6c935e2e3acb3145bfbd490758b34d2c70)
2000-10-05 22:19:34 +00:00
Andrew Tridgell
b76e942639 dump in a binary format
(This used to be commit 41af3232dba90832684ad8260ce0bb05e077cb02)
2000-04-24 14:36:44 +00:00
Tim Potter
3848759a5e Added standard shell command thing using '!' as first character.
(This used to be commit 829e645f62ffa16041c0cc126174d6fe8f63a2f0)
2000-03-13 01:35:09 +00:00
Tim Potter
79691801f4 Modifications to tdb_traverse() arguments to remove compile warnings.
(This used to be commit d64456b5889f0ee3a8c2108c13789540bfc3d90c)
2000-02-28 00:37:13 +00:00
Luke Leighton
bbe275e95b 1) added void* state argument to tdb_traverse. guess what! there were
two places i found where it was appropriate to _use_ that third argument,
in locking.c and brlock.c!  there was a static traverse_function and
i removed the static variable, typecast it to a void*, passed it to
tdb_traverse and re-cast it back to the traverse_function inside the
tdb_traverse function.  this makes the use of tdb_traverse() reentrant,
which is never going to happen, i know, i just don't like to see
statics lying about when there's no need for them.

as i had to do in samba-tng, all uses of tdb_traverse modified to take
the new void* state argument.

2) disabled rpcclient: referring people to use SAMBA_TNG rpcclient.
i don't know how the other samba team members would react if i deleted
rpcclient from cvs main.  damn, that code's so old, it's unreal.
20 rpcclient commands, instead of about 70 in SAMBA_TNG.
(This used to be commit 49d7f0afbc1c5425d53019e234d54ddf205c8e9a)
2000-02-04 04:59:31 +00:00
Andrew Tridgell
112faa49e6 don't require readline
(This used to be commit 2dbe70da8db548b3423c6c0de0f282fdf82f0fad)
2000-01-07 03:02:13 +00:00
Andrew Tridgell
9a781a8c6d - added tdb_flags option to tdb_open()
- added TDB_CLEAR_IF_FIRST flag to clear the database if this is the
  first attached process. Useful for non-persistent databases like our
  locking area (this will also make upgrades to new database layouts easier)
- use lock_path() in a couple of places
- leave connections database open while smbd running
- cleaned up some tdb code a little, using macros for constants
(This used to be commit 00e9da3ca577527db392aced62f02c69cfee8f4f)
2000-01-02 23:00:27 +00:00
Andrew Tridgell
d6a5878c76 fixed more locking bugs - all seems OK now
(This used to be commit 584537961b6134a50089d37328a21c617bc6547b)
1999-12-24 08:45:02 +00:00
Andrew Tridgell
c2c42b8694 first pass at the database code for Samba. This also includes a test
suite and a very simple tool for manuipulating the databases.

the main code is in tdb/tdb.c and includes both mmap and file based
IO. All databases auto-expand and allow multiple simultaneous writers.

the next step is using this new capability in lots of places in Samba
where we have existing ad-hoc databases
(This used to be commit c89d29cc5e3b6d568928acace01144059f1668b3)
1999-12-21 03:04:37 +00:00