[Git][NTPsec/ntpsec][master] Fix compiler warnings on osx

Eric S. Raymond gitlab at mg.gitlab.com
Tue Sep 27 01:53:06 UTC 2016


Eric S. Raymond pushed to branch master at NTPsec / ntpsec


Commits:
72590740 by Matt Selsky at 2016-09-26T20:47:36-04:00
Fix compiler warnings on osx

warning: format specifies type 'unsigned long' but the argument has type '__darwin_suseconds_t' (aka 'int') [-Wformat]

Fixes issue 118

- - - - -


1 changed file:

- tests/libntp/timevalops.c


Changes:

=====================================
tests/libntp/timevalops.c
=====================================
--- a/tests/libntp/timevalops.c
+++ b/tests/libntp/timevalops.c
@@ -76,10 +76,10 @@ static bool AssertTimevalClose(const struct timeval m, const struct timeval n,
 		return true;
 	else 
 	{
-		printf("m_expr which is %ld.%lu \nand\nn_expr which is %ld.%lu\nare not close; diff=%ld.%luusec\n",
-		       (long)m.tv_sec, m.tv_usec,
-		       (long)n.tv_sec, n.tv_usec,
-		       (long)diff.tv_sec, diff.tv_usec); 
+		printf("m_expr which is %ld.%ld \nand\nn_expr which is %ld.%ld\nare not close; diff=%ld.%ldusec\n",
+		       (long)m.tv_sec, (long)m.tv_usec,
+		       (long)n.tv_sec, (long)n.tv_usec,
+		       (long)diff.tv_sec, (long)diff.tv_usec);
 		//I don't have variables m_expr and n_expr in unity, those are command line arguments which only getst has!!!
 
 		return false;



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/72590740a7c5410199539da5b6560d458a3a41a1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ntpsec.org/pipermail/vc/attachments/20160927/40ef7d37/attachment.html>


More information about the vc mailing list