Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
2b2eca1f
Commit
2b2eca1f
authored
Dec 14, 2010
by
Pieter Noordhuis
Browse files
Zero-pad timestamps in MONITOR output
Original report and fix:
http://code.google.com/p/redis/issues/detail?id=404
parent
5ce3a24d
Changes
1
Show whitespace changes
Inline
Side-by-side
src/replication.c
View file @
2b2eca1f
...
@@ -88,7 +88,7 @@ void replicationFeedMonitors(list *monitors, int dictid, robj **argv, int argc)
...
@@ -88,7 +88,7 @@ void replicationFeedMonitors(list *monitors, int dictid, robj **argv, int argc)
struct
timeval
tv
;
struct
timeval
tv
;
gettimeofday
(
&
tv
,
NULL
);
gettimeofday
(
&
tv
,
NULL
);
cmdrepr
=
sdscatprintf
(
cmdrepr
,
"%ld.%ld "
,(
long
)
tv
.
tv_sec
,(
long
)
tv
.
tv_usec
);
cmdrepr
=
sdscatprintf
(
cmdrepr
,
"%ld.%
06
ld "
,(
long
)
tv
.
tv_sec
,(
long
)
tv
.
tv_usec
);
if
(
dictid
!=
0
)
cmdrepr
=
sdscatprintf
(
cmdrepr
,
"(db %d) "
,
dictid
);
if
(
dictid
!=
0
)
cmdrepr
=
sdscatprintf
(
cmdrepr
,
"(db %d) "
,
dictid
);
for
(
j
=
0
;
j
<
argc
;
j
++
)
{
for
(
j
=
0
;
j
<
argc
;
j
++
)
{
...
...
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