Ondřej Kuzník [Mon, 23 Jan 2023 11:48:33 +0000 (11:48 +0000)]
ITS#9045 rlock only if there may be other threads
We can't rlock if we've registered ourselves as a writer. We can only
figure that out by checking if we're the thread that initiated the
pause: is the server paused already?
Ondřej Kuzník [Wed, 18 Jan 2023 12:28:05 +0000 (12:28 +0000)]
ITS#9930 Just wait until si_mutex is ready
We're in a much better place now and there is only a single task active
for a given syncinfo_t plus the task that's just scheduled it and is
wrapping up. Any remaining times this wouldn't be true are probably bugs
to be fixed.
Ondřej Kuzník [Wed, 18 Jan 2023 13:03:23 +0000 (13:03 +0000)]
ITS#9983 Rework op->o_refcnt decref sequencing
epoch_append should be called at the point the object is not reachable
anymore, otherwise a thread from a "future" might still access it post
reclamation.
Howard Chu [Thu, 3 Nov 2022 17:42:36 +0000 (17:42 +0000)]
ITS#9929: more performance tweaks
For simple (non-nested) member compares, avoid unnecessary fetches
of dyngroups that can't match the filter.
cache filter/entry instance info across multiple dyn entries to
avoid refetching each filter entry for each dyngruop test.
Howard Chu [Tue, 15 Nov 2022 15:33:48 +0000 (15:33 +0000)]
ITS#9916 liblmdb: use alternate MDB_page2 struct for some accesses
fakepage pointers are only guaranteed to be 2-byte aligned. Use a
2-byte aligned struct definition when referencing 2-byte page members
if a page pointer possibly points to a fakepage.
Ondřej Kuzník [Wed, 26 Oct 2022 14:55:18 +0000 (15:55 +0100)]
ITS#9045 Do not share cn=config entries with outside code
config_back_entry_get currently returns the entry directly without
securing the rwlock, which is unsafe. However we can't keep holding it
on return in case the caller decides to hold onto the entry
indefinitely, hence rlock+entry_dup+runlock.
Connor Smith [Mon, 3 Oct 2022 10:11:10 +0000 (11:11 +0100)]
ITS#9925 Fix some ancient #ifdef checks
Use #elif defined(...) for HAVE_WINSOCK and MACOS. All other instances
of these macros use #ifdef or similar. A compiler may warn about them
not being defined.
In libraries/liblber/sockbuf.c, (DOS && PCNFS) and (DOS && NCSA) were
replaced with HAVE_PCNFS and HAVE_NCSA, respectively. It seems logical
to do the same at the only remaining occurrence of DOS, PCNFS, and NCSA.
Use #if HARDCODE_DATA consistently, replacing two instances of #ifdef.
HARDCODE_DATA is always defined, and this way you can set HARDCODE_DATA
to 0 and have it work, rather than it going down the wrong branch and
failing in these two cases.
Howard Chu [Sun, 9 Oct 2022 10:51:54 +0000 (11:51 +0100)]
ITS#9929 dynlist: avoid unnecessary search for dynamic lists
Was broken if only dynamic lists were configured, and not groups. Optional config URIs were being ignored. Don't prevent returning dynamic lists if dynamic groups were part of search.
Thomas Daniels [Mon, 19 Sep 2022 22:30:05 +0000 (00:30 +0200)]
ITS#9917 Remove 'h' and 'p' from options[] in client tools
The options -h and -p got removed from client tools in commit 66af4cfd5d3c559fcdf6d722b02fa66416b95f01. However, they were still
present in the options[] array in several client tools source files. So,
if one of those tools got executed with -h or -p followed by a value,
this lead to the error "unrecognized option -", without mentioning
which option was problematic. Removing 'h' and 'p' from options[] fixes
this.