projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
973698d
)
ts: do call localtime() when neither -s nor -i specified
author
Denys Vlasenko
<vda.linux@googlemail.com>
Tue, 26 Mar 2019 10:51:21 +0000
(11:51 +0100)
committer
Denys Vlasenko
<vda.linux@googlemail.com>
Tue, 26 Mar 2019 10:51:21 +0000
(11:51 +0100)
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
miscutils/ts.c
patch
|
blob
|
history
diff --git
a/miscutils/ts.c
b/miscutils/ts.c
index 4e1c7739f9320af254e77a4efcd3baee7f0648cd..f2d36765422f4f6c232c2d1219fab73be23ee7b6 100644
(file)
--- a/
miscutils/ts.c
+++ b/
miscutils/ts.c
@@
-69,8
+69,8
@@
int ts_main(int argc UNUSED_PARAM, char **argv)
}
if (opt & 1) /* -i */
base = ts1;
- localtime_r(&ts.tv_sec, &tm_time);
}
+ localtime_r(&ts.tv_sec, &tm_time);
strftime(date_buf, COMMON_BUFSIZE, fmt_dt2str, &tm_time);
if (!frac) {
printf("%s %s", date_buf, line);