Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
OpenLDAP
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
James Lowden
OpenLDAP
Commits
3e9b558a
Commit
3e9b558a
authored
14 years ago
by
Quanah Gibson-Mount
Browse files
Options
Downloads
Patches
Plain Diff
ITS#5340 fixes
parent
85e7991d
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
CHANGES
+1
-0
1 addition, 0 deletions
CHANGES
servers/slapd/proto-slap.h
+4
-0
4 additions, 0 deletions
servers/slapd/proto-slap.h
servers/slapd/result.c
+44
-0
44 additions, 0 deletions
servers/slapd/result.c
servers/slapd/slap.h
+1
-0
1 addition, 0 deletions
servers/slapd/slap.h
with
50 additions
and
0 deletions
CHANGES
+
1
−
0
View file @
3e9b558a
...
...
@@ -6,6 +6,7 @@ OpenLDAP 2.4.21 Release (2009/12/20)
Fixed liblutil for negative microsecond offsets (ITS#6405)
Fixed slapd global settings to work without restart (ITS#6428)
Fixed slapd looping with SSL/TLS connections (ITS#6412)
Fixed slapd REP_ENTRY flag handling (ITS#5340)
Fixed slapd syncrepl freeing tasks from queue (ITS#6413)
Fixed slapd syncrepl parsing of tls defaults (ITS#6419)
Fixed slapd syncrepl uninitialized variables (ITS#6425)
...
...
This diff is collapsed.
Click to expand it.
servers/slapd/proto-slap.h
+
4
−
0
View file @
3e9b558a
...
...
@@ -1512,6 +1512,10 @@ LDAP_SLAPD_F (int) get_alias_dn LDAP_P((
/*
* result.c
*/
LDAP_SLAPD_F
(
void
)
rs_replace_entry
LDAP_P
((
Operation
*
op
,
SlapReply
*
rs
,
slap_overinst
*
on
,
Entry
*
e
));
LDAP_SLAPD_F
(
int
)
rs_ensure_entry_modifiable
LDAP_P
((
Operation
*
op
,
SlapReply
*
rs
,
slap_overinst
*
on
));
LDAP_SLAPD_F
(
void
)
slap_send_ldap_result
LDAP_P
((
Operation
*
op
,
SlapReply
*
rs
));
LDAP_SLAPD_F
(
void
)
send_ldap_sasl
LDAP_P
((
Operation
*
op
,
SlapReply
*
rs
));
LDAP_SLAPD_F
(
void
)
send_ldap_disconnect
LDAP_P
((
Operation
*
op
,
SlapReply
*
rs
));
...
...
This diff is collapsed.
Click to expand it.
servers/slapd/result.c
+
44
−
0
View file @
3e9b558a
...
...
@@ -132,6 +132,50 @@ slap_req2res( ber_tag_t tag )
return
tag
;
}
#ifdef RS_ASSERT
#elif 0 && defined LDAP_DEVEL
/* FIXME: this should not crash. ITS#5340. */
#define RS_ASSERT assert
#else
#define RS_ASSERT(cond) ((void) 0)
#endif
/* Set rs->sr_entry after obyeing and clearing sr_flags & REP_ENTRY_MASK. */
void
rs_replace_entry
(
Operation
*
op
,
SlapReply
*
rs
,
slap_overinst
*
on
,
Entry
*
e
)
{
slap_mask_t
e_flags
=
rs
->
sr_flags
&
REP_ENTRY_MUSTFLUSH
;
if
(
e_flags
&&
rs
->
sr_entry
!=
NULL
)
{
RS_ASSERT
(
e_flags
!=
REP_ENTRY_MUSTFLUSH
);
if
(
!
(
e_flags
&
REP_ENTRY_MUSTRELEASE
)
)
{
entry_free
(
rs
->
sr_entry
);
}
else
if
(
on
!=
NULL
)
{
overlay_entry_release_ov
(
op
,
rs
->
sr_entry
,
0
,
on
);
}
else
{
be_entry_release_rw
(
op
,
rs
->
sr_entry
,
0
);
}
}
rs
->
sr_flags
&=
~
REP_ENTRY_MASK
;
rs
->
sr_entry
=
e
;
}
/*
* Ensure rs->sr_entry is modifiable, by duplicating it if necessary.
* Obey sr_flags. Set REP_ENTRY_<MODIFIABLE, and MUSTBEFREED if duplicated>.
* Return nonzero if rs->sr_entry was replaced.
*/
int
rs_ensure_entry_modifiable
(
Operation
*
op
,
SlapReply
*
rs
,
slap_overinst
*
on
)
{
if
(
rs
->
sr_flags
&
REP_ENTRY_MODIFIABLE
)
{
RS_ASSERT
((
rs
->
sr_flags
&
REP_ENTRY_MUSTFLUSH
)
==
REP_ENTRY_MUSTBEFREED
);
return
0
;
}
rs_replace_entry
(
op
,
rs
,
on
,
entry_dup
(
rs
->
sr_entry
));
rs
->
sr_flags
|=
REP_ENTRY_MODIFIABLE
|
REP_ENTRY_MUSTBEFREED
;
return
1
;
}
static
long
send_ldap_ber
(
Operation
*
op
,
BerElement
*
ber
)
...
...
This diff is collapsed.
Click to expand it.
servers/slapd/slap.h
+
1
−
0
View file @
3e9b558a
...
...
@@ -2090,6 +2090,7 @@ struct SlapReply {
#define REP_ENTRY_MUSTBEFREED 0x0002U
#define REP_ENTRY_MUSTRELEASE 0x0004U
#define REP_ENTRY_MASK (REP_ENTRY_MODIFIABLE|REP_ENTRY_MUSTBEFREED|REP_ENTRY_MUSTRELEASE)
#define REP_ENTRY_MUSTFLUSH (REP_ENTRY_MUSTBEFREED|REP_ENTRY_MUSTRELEASE)
#define REP_MATCHED_MUSTBEFREED 0x0010U
#define REP_MATCHED_MASK (REP_MATCHED_MUSTBEFREED)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment