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
Christopher Ng
OpenLDAP
Commits
2b772788
Commit
2b772788
authored
23 years ago
by
Kurt Zeilenga
Browse files
Options
Downloads
Patches
Plain Diff
misc updates, constification, deprecation...
parent
e17f0256
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
include/ldap.h
+1
-1
1 addition, 1 deletion
include/ldap.h
include/ldap_log.h
+7
-4
7 additions, 4 deletions
include/ldap_log.h
libraries/libldap/friendly.c
+5
-5
5 additions, 5 deletions
libraries/libldap/friendly.c
libraries/liblutil/debug.c
+4
-4
4 additions, 4 deletions
libraries/liblutil/debug.c
with
17 additions
and
14 deletions
include/ldap.h
+
1
−
1
View file @
2b772788
...
...
@@ -1441,7 +1441,7 @@ ldap_mods_free LDAP_P((
LDAP_F
(
char
*
)
ldap_friendly_name
LDAP_P
((
/* deprecated */
LDAP_CONST
char
*
filename
,
/*
LDAP_CONST
*/
char
*
uname
,
LDAP_CONST
char
*
uname
,
LDAPFriendlyMap
**
map
));
LDAP_F
(
void
)
...
...
This diff is collapsed.
Click to expand it.
include/ldap_log.h
+
7
−
4
View file @
2b772788
...
...
@@ -135,10 +135,13 @@ LDAP_BEGIN_DECL
#endif
/* LDAP_DEBUG */
LDAP_LUTIL_F
(
int
)
lutil_mnem2level
LDAP_P
((
char
*
level
));
LDAP_LUTIL_F
(
void
)
lutil_log_initialize
(
int
argc
,
char
**
argv
);
LDAP_LUTIL_F
(
void
)
lutil_set_debug_level
LDAP_P
((
char
*
subsys
,
int
level
));
LDAP_LUTIL_F
(
void
)
lutil_log
LDAP_P
((
char
*
subsys
,
int
level
,
const
char
*
fmt
,
...
));
LDAP_LUTIL_F
(
int
)
lutil_mnem2level
LDAP_P
((
const
char
*
level
));
LDAP_LUTIL_F
(
void
)
lutil_log_initialize
LDAP_P
((
int
argc
,
char
**
argv
));
LDAP_LUTIL_F
(
void
)
lutil_set_debug_level
LDAP_P
((
const
char
*
subsys
,
int
level
));
LDAP_LUTIL_F
(
void
)
lutil_log
LDAP_P
((
const
char
*
subsys
,
int
level
,
const
char
*
fmt
,
...
));
LDAP_LUTIL_F
(
int
)
lutil_debug_file
LDAP_P
((
FILE
*
file
));
...
...
This diff is collapsed.
Click to expand it.
libraries/libldap/friendly.c
+
5
−
5
View file @
2b772788
...
...
@@ -25,7 +25,7 @@
char
*
ldap_friendly_name
(
LDAP_CONST
char
*
filename
,
/*
LDAP_CONST
*/
char
*
uname
,
LDAP_CONST
char
*
uname
,
LDAPFriendlyMap
**
map
)
{
int
i
,
entries
;
...
...
@@ -35,12 +35,12 @@ ldap_friendly_name(
if
(
map
==
NULL
)
{
errno
=
EINVAL
;
return
(
uname
)
;
return
(
char
*
)
uname
;
}
if
(
*
map
==
NULL
)
{
if
(
(
fp
=
fopen
(
filename
,
"r"
))
==
NULL
)
return
(
uname
)
;
return
(
char
*
)
uname
;
entries
=
0
;
while
(
fgets
(
buf
,
sizeof
(
buf
),
fp
)
!=
NULL
)
{
...
...
@@ -52,7 +52,7 @@ ldap_friendly_name(
if
(
(
*
map
=
(
LDAPFriendlyMap
*
)
LDAP_MALLOC
(
(
entries
+
1
)
*
sizeof
(
LDAPFriendlyMap
)
))
==
NULL
)
{
fclose
(
fp
);
return
(
uname
)
;
return
(
char
*
)
uname
;
}
i
=
0
;
...
...
@@ -99,7 +99,7 @@ ldap_friendly_name(
if
(
strcasecmp
(
uname
,
(
*
map
)[
i
].
lf_unfriendly
)
==
0
)
return
(
(
*
map
)[
i
].
lf_friendly
);
}
return
(
uname
)
;
return
(
char
*
)
uname
;
}
...
...
This diff is collapsed.
Click to expand it.
libraries/liblutil/debug.c
+
4
−
4
View file @
2b772788
...
...
@@ -49,7 +49,7 @@ static char *lutil_levels[] = {"emergency", "alert", "critical",
"results"
,
"detail1"
,
"detail2"
,
NULL
};
int
lutil_mnem2level
(
char
*
level
)
int
lutil_mnem2level
(
const
char
*
level
)
{
int
i
;
for
(
i
=
0
;
lutil_levels
[
i
]
!=
NULL
;
i
++
)
...
...
@@ -97,7 +97,7 @@ static void addSubsys( const char *subsys, int level )
return
;
}
void
lutil_set_debug_level
(
char
*
subsys
,
int
level
)
void
lutil_set_debug_level
(
const
char
*
subsys
,
int
level
)
{
addSubsys
(
subsys
,
level
);
}
...
...
@@ -112,7 +112,7 @@ int lutil_debug_file( FILE *file )
void
lutil_log_int
(
FILE
*
file
,
char
*
subsys
,
int
level
,
const
char
*
subsys
,
int
level
,
const
char
*
fmt
,
va_list
vl
)
{
time_t
now
;
...
...
@@ -199,7 +199,7 @@ void lutil_log_int(
* level of the log output and the format and data. Send this on to the
* internal routine with the print file, if any.
*/
void
lutil_log
(
char
*
subsys
,
int
level
,
const
char
*
fmt
,
...
)
void
lutil_log
(
const
char
*
subsys
,
int
level
,
const
char
*
fmt
,
...
)
{
FILE
*
outfile
=
NULL
;
va_list
vl
;
...
...
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