Skip to content

Commit f881599

Browse files
committed
Fix compilation on sparc with gcc 4.9
src/libumockdev-preload.c:964:4: error: format '%li' expects argument of type 'long int', but argument 4 has type '__suseconds_t' [-Werror=format=] e->time.tv_sec, e->time.tv_usec, e->type, e->code, e->value);
1 parent 82e8a8d commit f881599

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

NEWS

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
0.8.6 (UNRELEASED)
2+
------------------
3+
- Fix compilation on sparc with gcc 4.9.
4+
15
0.8.5 (2014-07-11)
26
------------------
37
- Fix building with gcc 4.9 on 32 bit architectures.

src/libumockdev-preload.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -961,7 +961,7 @@ script_record_op(char op, int fd, const void *buf, ssize_t size)
961961
const struct input_event *e = buf;
962962
while (size > 0) {
963963
fprintf(srinfo->log, "E: %li.%06li %04"PRIX16" %04"PRIX16 " %"PRIi32"\n",
964-
e->time.tv_sec, e->time.tv_usec, e->type, e->code, e->value);
964+
(long) e->time.tv_sec, (long) e->time.tv_usec, e->type, e->code, e->value);
965965
size -= sizeof(struct input_event);
966966
e++;
967967
}

0 commit comments

Comments
 (0)