Browse Source

help the compiler a bit with a cast, spotted by theo

OPENBSD_3_6
henning 20 years ago
parent
commit
727098a446
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/usr.sbin/ntpd/util.c

+ 2
- 2
src/usr.sbin/ntpd/util.c View File

@ -1,4 +1,4 @@
/* $OpenBSD: util.c,v 1.6 2004/07/07 07:32:05 alexander Exp $ */
/* $OpenBSD: util.c,v 1.7 2004/07/07 07:38:21 henning Exp $ */
/* /*
* Copyright (c) 2004 Alexander Guy <alexander.guy@andern.org> * Copyright (c) 2004 Alexander Guy <alexander.guy@andern.org>
@ -57,7 +57,7 @@ d_to_lfp(double d)
{ {
struct l_fixedpt lfp; struct l_fixedpt lfp;
lfp.int_part = htonl(d);
lfp.int_part = htonl((u_int32_t)d);
lfp.fraction = htonl((u_int32_t)((d - (u_int32_t)d) * UINT_MAX)); lfp.fraction = htonl((u_int32_t)((d - (u_int32_t)d) * UINT_MAX));
return (lfp); return (lfp);


Loading…
Cancel
Save