blob: 00e6657e091229316c77290085f68374c3c87a94 [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001When try to print time_t values as a long int it causes an error because time_t
2data type in x32 ABI is long long int.
3
4Upstream-Status: Pending
5
6Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
7
Brad Bishop316dfdd2018-06-25 12:45:53 -04008Index: mdadm-4.0/monitor.c
Patrick Williamsc124f4f2015-09-15 14:41:29 -05009===================================================================
Brad Bishop316dfdd2018-06-25 12:45:53 -040010--- mdadm-4.0.orig/monitor.c
11+++ mdadm-4.0/monitor.c
12@@ -445,9 +445,12 @@ static int read_and_act(struct active_ar
13 if (FD_ISSET(mdi->bb_fd, fds))
14 check_for_cleared_bb(a, mdi);
Patrick Williamsc124f4f2015-09-15 14:41:29 -050015 }
16-
17 gettimeofday(&tv, NULL);
18+#if defined(__x86_64__) && defined(__ILP32__)
19+ dprintf("(%d): %lld.%06lld state:%s prev:%s action:%s prev: %s start:%llu\n",
20+#else
21 dprintf("(%d): %ld.%06ld state:%s prev:%s action:%s prev: %s start:%llu\n",
22+#endif
23 a->info.container_member,
24 tv.tv_sec, tv.tv_usec,
25 array_states[a->curr_state],