summaryrefslogtreecommitdiff
path: root/bin/md5
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2020-10-19 18:15:19 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2020-10-19 18:15:19 +0000
commit12554501528b3044dc0f9128caffbc70ee6609c9 (patch)
tree8406bfd1d8055d7d50e0a121e566109035b2cd50 /bin/md5
parent4b0184132331fc46239f426cf0962306178e6e34 (diff)
Add explicit casts to double to quiet a clang warning.
OK deraddt@
Diffstat (limited to 'bin/md5')
-rw-r--r--bin/md5/md5.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/md5/md5.c b/bin/md5/md5.c
index c58863c48e3..c2245eb91e4 100644
--- a/bin/md5/md5.c
+++ b/bin/md5/md5.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: md5.c,v 1.96 2020/10/03 00:37:06 millert Exp $ */
+/* $OpenBSD: md5.c,v 1.97 2020/10/19 18:15:18 millert Exp $ */
/*
* Copyright (c) 2001,2003,2005-2007,2010,2013,2014
@@ -778,7 +778,7 @@ digest_time(struct hash_list *hl, int times)
digest_end(hf, &context, digest, sizeof(digest), hf->base64);
getrusage(RUSAGE_SELF, &stop);
timersub(&stop.ru_utime, &start.ru_utime, &res);
- elapsed = res.tv_sec + res.tv_usec / 1000000.0;
+ elapsed = (double)res.tv_sec + (double)res.tv_usec / 1000000.0;
(void)printf("\nDigest = %s\n", digest);
(void)printf("Time = %f seconds\n", elapsed);