Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Michael Black
OpenXG-RAN
Commits
2eb0d4c9
Commit
2eb0d4c9
authored
May 12, 2016
by
Cedric Roux
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add time to textlog if available
parent
df5afaa9
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
common/utils/T/tracer/logger/textlog.c
common/utils/T/tracer/logger/textlog.c
+12
-0
No files found.
common/utils/T/tracer/logger/textlog.c
View file @
2eb0d4c9
...
...
@@ -37,9 +37,21 @@ static void _event(void *p, event e)
{
struct
textlog
*
l
=
p
;
int
i
;
#ifdef T_SEND_TIME
struct
tm
*
t
;
char
tt
[
64
];
#endif
l
->
o
.
osize
=
0
;
#ifdef T_SEND_TIME
t
=
localtime
(
&
e
.
sending_time
.
tv_sec
);
/* round tv_nsec to nearest millisecond */
sprintf
(
tt
,
"%2.2d:%2.2d:%2.2d.%3.3d: "
,
t
->
tm_hour
,
t
->
tm_min
,
t
->
tm_sec
,
(
int
)((
e
.
sending_time
.
tv_nsec
/
(
1000000
/
2
)
+
1
)
/
2
));
PUTS
(
&
l
->
o
,
tt
);
#endif
for
(
i
=
0
;
i
<
l
->
fsize
;
i
++
)
switch
(
l
->
f
[
i
].
type
)
{
case
INSTRING
:
PUTS
(
&
l
->
o
,
l
->
f
[
i
].
s
);
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment