Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[xsrc/trunk]: xsrc/external/mit/xclock/dist - add likely missing () around ||...
details: https://anonhg.NetBSD.org/xsrc/rev/66b4ae4f508f
branches: trunk
changeset: 10171:66b4ae4f508f
user: mrg <mrg%NetBSD.org@localhost>
date: Mon Mar 04 08:28:59 2019 +0000
description:
- add likely missing () around || expression.
- use fabsl() not abs().
both picked up by clang and the new xclock.
diffstat:
external/mit/xclock/dist/Clock.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (27 lines):
diff -r b51ad59dd803 -r 66b4ae4f508f external/mit/xclock/dist/Clock.c
--- a/external/mit/xclock/dist/Clock.c Mon Mar 04 08:21:03 2019 +0000
+++ b/external/mit/xclock/dist/Clock.c Mon Mar 04 08:28:59 2019 +0000
@@ -1610,8 +1610,8 @@
RenderHands (w, &tm, False);
}
if (w->clock.show_second_hand &&
- tm.tm_sec != w->clock.otm.tm_sec ||
- tv.tv_usec != w->clock.otv.tv_usec)
+ (tm.tm_sec != w->clock.otm.tm_sec ||
+ tv.tv_usec != w->clock.otv.tv_usec))
{
RenderSec (w, &w->clock.otm, &w->clock.otv, False);
RenderSec (w, &tm, &tv, False);
@@ -2173,10 +2173,10 @@
if (new->clock.update && XtIsRealized( (Widget) new))
new->clock.interval_id = XtAppAddTimeOut(
XtWidgetToApplicationContext(gnew),
- abs(new->clock.update)*1000,
+ fabsl(new->clock.update)*1000,
clock_tic, (XtPointer)gnew);
- new->clock.show_second_hand =(abs(new->clock.update) <= SECOND_HAND_TIME);
+ new->clock.show_second_hand =(fabsl(new->clock.update) <= SECOND_HAND_TIME);
if (new->clock.show_second_hand != current->clock.show_second_hand)
redisplay = TRUE;
}
Home |
Main Index |
Thread Index |
Old Index