Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libxseg
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
itminedu
libxseg
Commits
c389ef80
Commit
c389ef80
authored
10 years ago
by
Stratos Psomadakis
Browse files
Options
Downloads
Patches
Plain Diff
Re-add renew_logctx
parent
235d20b6
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/exports/xseg_exports.h
+1
-0
1 addition, 0 deletions
src/exports/xseg_exports.h
src/include/xseg/domain.h
+1
-0
1 addition, 0 deletions
src/include/xseg/domain.h
src/xseg_user.c
+10
-0
10 additions, 0 deletions
src/xseg_user.c
with
12 additions
and
0 deletions
src/exports/xseg_exports.h
+
1
−
0
View file @
c389ef80
...
...
@@ -65,6 +65,7 @@ EXPORT_SYMBOL(xseg_leave_dynport);
EXPORT_SYMBOL
(
xseg_portno_nonstatic
);
EXPORT_SYMBOL
(
__xseg_errbuf
);
EXPORT_SYMBOL
(
renew_logctx
);
EXPORT_SYMBOL
(
init_logctx
);
EXPORT_SYMBOL
(
__xseg_log2
);
EXPORT_SYMBOL
(
xseg_printtrace
);
This diff is collapsed.
Click to expand it.
src/include/xseg/domain.h
+
1
−
0
View file @
c389ef80
...
...
@@ -37,6 +37,7 @@ extern char __xseg_errbuf[4096];
enum
log_level
{
E
=
0
,
W
=
1
,
I
=
2
,
D
=
3
};
extern
void
(
*
renew_logctx
)(
enum
log_level
level
);
extern
void
(
*
init_logctx
)(
char
*
peer_name
,
enum
log_level
level
);
void
__xseg_log2
(
enum
log_level
level
,
char
*
fmt
,
...);
...
...
This diff is collapsed.
Click to expand it.
src/xseg_user.c
+
10
−
0
View file @
c389ef80
...
...
@@ -114,6 +114,16 @@ static inline int get_syslog_level(enum log_level level) {
return
syslog_level
;
}
static
void
__renew_logctx
(
enum
log_level
level
)
{
/* FIXME: LOG_UPTO portability */
setlogmask
(
LOG_UPTO
(
get_syslog_level
(
level
)));
return
;
}
void
(
*
renew_logctx
)(
enum
log_level
level
)
=
__renew_logctx
;
static
void
__init_logctx
(
char
*
peer_name
,
enum
log_level
level
)
{
openlog
(
peer_name
,
LOG_PID
|
LOG_CONS
,
LOG_LOCAL0
);
...
...
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