Commit Graph

172 Commits

Author SHA1 Message Date
Hallvard Furuseth
169d6d0200 Add entry.c to complete previous change 1999-04-13 06:15:03 +00:00
Hallvard Furuseth
62aa401bd7 Add struct backend_info->bi_entry_release_rw and related functions.
Move cache_return_entry_w() out of ldbm_back_add when the add is successful.
This change breaks back-bdb2, it needs equvalent changes of those in back-ldbm.
1999-04-13 06:08:28 +00:00
Kurt Zeilenga
ad35a9d4a6 Add trace message when found entry is busy. 1999-04-11 22:16:30 +00:00
Hallvard Furuseth
59e7798448 Fix typo ldap_pvt_thread_mutex_lock -> ldap_pvt_thread_mutex_unlock 1999-04-11 19:36:19 +00:00
Kurt Zeilenga
f16846eb15 Apply LDBM cache changes (c_mutex streamlining) to BDB2 and back. 1999-04-10 04:28:02 +00:00
Kurt Zeilenga
0317638cf6 Addition streamlining of code behind c_mutex. 1999-04-10 01:35:19 +00:00
Kurt Zeilenga
f34bd50e30 Streamline code during finds to reduce contention on c_mutex.
Move Debug messages outside of c_mutex.  Other LDBM cache codes
also should be streamlined.  Resultant approaches should then
be applied to back-bdb2.
1999-04-09 18:33:52 +00:00
Kurt Zeilenga
a28f9e03be More errno handling changes for FreeBSD LinuxThreads. 1999-04-08 04:17:32 +00:00
Hallvard Furuseth
d9d11a315f ifdef SLAP_CLEANUP: close db files, free memory, some other cleanup before exit 1999-04-06 01:55:11 +00:00
Kurt Zeilenga
cf4371d108 Backout last change... finish my first coke... try again later... 1999-04-05 18:30:56 +00:00
Kurt Zeilenga
66164a1b58 Share unlock and return between true and false paths. 1999-04-05 18:21:31 +00:00
Hallvard Furuseth
dae494e45d Delay free(e.e_ndn) in cache_find_entry_dn2id() to after "goto try_again" 1999-04-05 18:01:11 +00:00
Hallvard Furuseth
2915ed56db plug memory leak of li->li_nextid_file 1999-04-04 21:53:39 +00:00
Hallvard Furuseth
db859cee36 strdup/free li->li_directory when chaning, so unmalloced version won't be freed 1999-04-04 21:49:56 +00:00
Hallvard Furuseth
47f9f7e79d fix typo in comment in ldbm_back_close 1999-04-04 21:39:24 +00:00
Hallvard Furuseth
2b32e6afd7 Plug memory leaks 1999-04-04 21:34:33 +00:00
Hallvard Furuseth
f172f7ee9c Remove superfluous \ at end of lines outside macros; DEC cc doesn't like them. 1999-04-03 09:20:41 +00:00
Kurt Zeilenga
e46877f89f cache: implement try_again loop if cache entry is not ready.
id2entry: when an error occurs attempting to insert fetched
entry into cache, check to see if entry was added by another
thread.  If so, return the entry added by the other thread.
The concurrency tests now run without the dreaded "no such object"
error messages!
1999-04-02 19:09:59 +00:00
Hallvard Furuseth
815a62930c UNDO LAST COMMIT. 1999-04-02 03:45:33 +00:00
Hallvard Furuseth
45118be88e Fix wait4child change: Prefer wait3 over wait. Use SIGNAL instead of signal. 1999-04-02 03:23:20 +00:00
Hallvard Furuseth
d5938af750 Enclose `DB_ENV li_db_env' declaration in #ifdef HAVE_BERKELEY_DB2 1999-04-01 22:18:09 +00:00
Kurt Zeilenga
dda1fb4ba0 Updates for NT4 (MSVC5++).
Removed external include/library paths from projects.  External paths should
be set via Tools | Options | Directories.  This allows each developer the
freedom to install external libraries where they desire.
Used libdb.lib instead of libdbs.lib to avoid thread conflicts.
Added hs_regex.lib to library input.  We require some form of regex, this
library works (and is relatively easy for the user to install).
Removed a little lint which MCVC5 detected.
Need to sort out single-threaded vs multithreaded library generation.
1999-04-01 20:26:09 +00:00
Gary Williams
e6b47355f9 NT port 1999-04-01 14:50:34 +00:00
Kurt Spanier
1c7ebc514f Some minor clean-up; checking bdb2 for sync with ldbm. 1999-04-01 09:58:36 +00:00
Will Ballantyne
4fbc5ed92c check for NULL newDN prior to final deref check 1999-03-26 05:36:26 +00:00
Juan Gomez
90ebcb8bd9 Added support for newSuperior. 1999-03-24 21:45:15 +00:00
Kurt Zeilenga
8f02beada9 PROTOTYPE: New connection management infrastructure designed to
remove race conditions on connection close.
BROKEN: various counters for dn=monitor.
Initial testing on FreeBSD (with and without pthreads) was successfull.
Have not yet tested preemptive threading environments.
Have not built against backends other than LDBM.
1999-03-22 07:14:54 +00:00
Juan Gomez
f8a0a67e5f Fixed a bug related to the deallocation of memory for new_dn and new_ndn,
They must not be deallocated since they are used by the cache entry.
1999-03-10 22:17:54 +00:00
Juan Gomez
c2a0632e63 Added support for deleteoldrdn. 1999-03-09 08:07:57 +00:00
Juan Gomez
b9f9b8805a Fixed type by changing rdn_type to new_rdn_type. 1999-03-09 00:42:57 +00:00
Juan Gomez
23b3217b66 Added software to add the new rdn as an attribute to the entry.
(First step towards full LDAPv2 support).
1999-03-07 09:31:54 +00:00
Hallvard Furuseth
3277a27b10 Remove unused variables 1999-03-06 16:29:05 +00:00
Juan Gomez
3ba99a75ef Added parameter newSuperior in preparation to support
LDAP v3 MODDN request.
1999-03-05 03:38:12 +00:00
Juan Gomez
ddf04f5900 Made add_values(), delete_values(), and replace_values() so they can be
used in implementing modrdn v3.
1999-03-03 22:00:16 +00:00
Juan Gomez
98c2a61313 Made add_values(), delete_values(), replace_values() so they can be used
for implementing modrdn v3.
1999-03-03 21:58:51 +00:00
Hallvard Furuseth
69a93a0582 function pointers are incompatible with `void *'; remove NULL or replace with 0 1999-03-03 17:02:10 +00:00
Bart Hartgers
e0fdd89432 Annoying little son of a `free' BUG fixed. 1999-03-02 20:14:11 +00:00
Kurt Zeilenga
4e160e83b6 Replace IFP() with appropriate full prototypes:
AVL_CMP, AVL_DUP, AVL_FREE, AVL_APPLY.
Apply casts as needed.
Change data pointer from caddr_t to void *.
1999-03-02 00:32:59 +00:00
Kurt Zeilenga
a8a05cbe48 Update NT port with support for -lldap_r and -lldbm.
Also add initial slapd .dsw/.dsp files.  Still needs work (mainly syslog).
1999-03-01 22:37:05 +00:00
Kurt Zeilenga
3984323bf9 Fix minor memory leak and remove redundant be_isroot_pw() checks.
Suggested by Pierangelo Masarati <pmasarati@bci.it> in post to -bugs.
1999-03-01 19:42:06 +00:00
Kurt Spanier
6e63b58a3e Update of back-bdb2 to KDZ's new entry lock schema.
Fix of a back-bdb2 --> back-ldbm leakage (==> new bdb2-specific DB file suffix).
1999-02-12 12:13:03 +00:00
Kurt Zeilenga
2a20131eaa Consistently use %ld for printing IDs. %lu was used in many cases.
I rather have NOID printed as "-1".  It it could argued that ID
should be signed.
1999-02-11 18:19:52 +00:00
Kurt Zeilenga
c2c0d9687f Complete entry_cmp() migration (remove rename macros). 1999-02-11 17:52:28 +00:00
Kurt Zeilenga
745a10f080 Update LDBM cache so that it manages it's own state.
cache_set_state() and state args are no history.
Move cache_entry_cmp() and friends to slapd/entry.c to allow sharing
of functions between backends..  Renamed to entry_cmp().
1999-02-11 17:46:56 +00:00
Kurt Zeilenga
88c43a1e6e Move LDBM-backend specific fields of Entry struct into a private struct.
The new e_private field can be used for any backend purpose.  In LDBM,
it's used to point th the private entry info struct.  The LDBM entry
info struct is only visible to the LDBM cache.
WARNING: This change has not be ported to other backends!  Breakage is likely.
1999-02-10 18:28:25 +00:00
Kurt Zeilenga
fc022ed0d4 Patch modrdn to remove extra space. 1999-02-09 17:58:13 +00:00
Kurt Spanier
42f6e78dd4 Integration of the BDB2 backend into the new init/startup/shutdown schema.
Integration into ./configure ( --enable-bdb2 ).
Adaptation of the test-suite ( 'make' -> ldbm; 'make bdb2-local' -> bdb2 ).
Minor fixes in slapd/libldbm.
1999-02-08 11:42:14 +00:00
Kurt Zeilenga
587535a310 Really fix those reader/writer lock asserts... 1999-02-07 17:57:50 +00:00
Kurt Zeilenga
7eaae29f6f Fix cache asserts on entry writer locks. 1999-02-07 02:50:10 +00:00
Kurt Zeilenga
dde7e3dfa6 Don't call idl_free() unless necessary. 1999-02-05 23:46:03 +00:00