Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
OpenLDAP
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review 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
François Kooman
OpenLDAP
Commits
727be55f
Commit
727be55f
authored
13 years ago
by
Quanah Gibson-Mount
Browse files
Options
Downloads
Patches
Plain Diff
ITS
#6845
parent
51caf177
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/add.c
+0
-3
0 additions, 3 deletions
servers/slapd/add.c
servers/slapd/attr.c
+2
-0
2 additions, 0 deletions
servers/slapd/attr.c
servers/slapd/back-bdb/modify.c
+12
-18
12 additions, 18 deletions
servers/slapd/back-bdb/modify.c
with
15 additions
and
21 deletions
CHANGES
+
1
−
0
View file @
727be55f
...
...
@@ -2,6 +2,7 @@ OpenLDAP 2.4 Change Log
OpenLDAP 2.4.25 Engineering
Fixed slapd add objectclasses in order (ITS#6837)
Fixed slapd sortval handling (ITS#6845)
Fixed slapd-ldap chain cn=config support (ITS#6837)
Fixed slapd-meta deadlock (ITS#6846)
Build Environment
...
...
This diff is collapsed.
Click to expand it.
servers/slapd/add.c
+
0
−
3
View file @
727be55f
...
...
@@ -500,9 +500,6 @@ slap_mods2entry(
}
else
{
attr
->
a_nvals
=
attr
->
a_vals
;
}
/* slap_mods_check() gives us sorted results */
if
(
attr
->
a_desc
->
ad_type
->
sat_flags
&
SLAP_AT_SORTED_VAL
)
attr
->
a_flags
|=
SLAP_ATTR_SORTED_VALS
;
*
tail
=
attr
;
tail
=
&
attr
->
a_next
;
...
...
This diff is collapsed.
Click to expand it.
servers/slapd/attr.c
+
2
−
0
View file @
727be55f
...
...
@@ -88,6 +88,8 @@ attr_alloc( AttributeDescription *ad )
ldap_pvt_thread_mutex_unlock
(
&
attr_mutex
);
a
->
a_desc
=
ad
;
if
(
ad
&&
(
ad
->
ad_type
->
sat_flags
&
SLAP_AT_SORTED_VAL
))
a
->
a_flags
|=
SLAP_ATTR_SORTED_VALS
;
return
a
;
}
...
...
This diff is collapsed.
Click to expand it.
servers/slapd/back-bdb/modify.c
+
12
−
18
View file @
727be55f
...
...
@@ -289,31 +289,23 @@ int bdb_modify_internal(
if
(
a2
)
{
/* need to detect which values were deleted */
int
i
,
j
;
struct
berval
tmp
;
j
=
ap
->
a_numvals
;
for
(
i
=
0
;
i
<
j
;
)
{
vals
=
op
->
o_tmpalloc
(
(
ap
->
a_numvals
+
1
)
*
sizeof
(
struct
berval
),
op
->
o_tmpmemctx
);
j
=
0
;
for
(
i
=
0
;
i
<
ap
->
a_numvals
;
i
++
)
{
rc
=
attr_valfind
(
a2
,
SLAP_MR_ASSERTED_VALUE_NORMALIZED_MATCH
,
&
ap
->
a_nvals
[
i
],
NULL
,
op
->
o_tmpmemctx
);
/* Move deleted values to end of array */
if
(
rc
==
LDAP_NO_SUCH_ATTRIBUTE
)
{
j
--
;
if
(
i
!=
j
)
{
tmp
=
ap
->
a_nvals
[
j
];
ap
->
a_nvals
[
j
]
=
ap
->
a_nvals
[
i
];
ap
->
a_nvals
[
i
]
=
tmp
;
tmp
=
ap
->
a_vals
[
j
];
ap
->
a_vals
[
j
]
=
ap
->
a_vals
[
i
];
ap
->
a_vals
[
i
]
=
tmp
;
}
continue
;
}
/* Save deleted values */
if
(
rc
==
LDAP_NO_SUCH_ATTRIBUTE
)
vals
[
j
++
]
=
ap
->
a_nvals
[
i
];
i
++
;
}
vals
=
&
ap
->
a_n
vals
[
j
]
;
BER_BVZERO
(
vals
+
j
)
;
}
else
{
/* attribute was completely deleted */
vals
=
ap
->
a_nvals
;
}
rc
=
0
;
if
(
!
BER_BVISNULL
(
vals
))
{
rc
=
bdb_index_values
(
op
,
tid
,
ap
->
a_desc
,
vals
,
e
->
e_id
,
SLAP_INDEX_DELETE_OP
);
...
...
@@ -323,9 +315,11 @@ int bdb_modify_internal(
op
->
o_log_prefix
,
ap
->
a_desc
->
ad_cname
.
bv_val
,
0
);
attrs_free
(
e
->
e_attrs
);
e
->
e_attrs
=
save_attrs
;
return
rc
;
}
}
if
(
vals
!=
ap
->
a_nvals
)
op
->
o_tmpfree
(
vals
,
op
->
o_tmpmemctx
);
if
(
rc
)
return
rc
;
}
}
...
...
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