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
Jaak Ristioja
OpenLDAP
Commits
a9871d74
Commit
a9871d74
authored
25 years ago
by
Hallvard Furuseth
Browse files
Options
Downloads
Patches
Plain Diff
Fix bitmasks '0xhh << n' to '(masked type)0xhh << n'
parent
2d4f915d
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libraries/liblber/encode.c
+3
-3
3 additions, 3 deletions
libraries/liblber/encode.c
with
3 additions
and
3 deletions
libraries/liblber/encode.c
+
3
−
3
View file @
a9871d74
...
...
@@ -142,7 +142,7 @@ ber_put_len( BerElement *ber, ber_len_t len, int nosos )
/* find the first non-all-zero byte */
for
(
i
=
sizeof
(
ber_len_t
)
-
1
;
i
>
0
;
i
--
)
{
mask
=
(
0xffU
<<
(
i
*
8
));
mask
=
(
(
ber_len_t
)
0xffU
<<
(
i
*
8
));
/* not all zero */
if
(
len
&
mask
)
break
;
...
...
@@ -186,7 +186,7 @@ ber_put_int_or_enum(
* high bit is clear - look for first non-all-zero byte
*/
for
(
i
=
sizeof
(
ber_int_t
)
-
1
;
i
>
0
;
i
--
)
{
mask
=
(
0xffU
<<
(
i
*
8
));
mask
=
(
(
ber_uint_t
)
0xffU
<<
(
i
*
8
));
if
(
sign
)
{
/* not all ones */
...
...
@@ -203,7 +203,7 @@ ber_put_int_or_enum(
* we now have the "leading byte". if the high bit on this
* byte matches the sign bit, we need to "back up" a byte.
*/
mask
=
(
unum
&
(
0x80U
<<
(
i
*
8
)));
mask
=
(
unum
&
(
(
ber_uint_t
)
0x80U
<<
(
i
*
8
)));
if
(
(
mask
&&
!
sign
)
||
(
sign
&&
!
mask
)
)
i
++
;
...
...
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