diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2012-11-25 21:34:10 +0100 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2012-11-25 21:43:44 +0100 |
commit | 29abad107f8610e73b2fc091216040b579c75453 (patch) | |
tree | 4eb62b9e179a79c45d73788858da9d0551262801 /src/journal/journal-send.c | |
parent | 8a3a1704c7738a49385e1e1a2a5041f50e79f57e (diff) |
journal: fix warning about pointer arithmetic
../src/journal/journal-send.c: In function 'sd_journal_sendv':
../src/journal/journal-send.c:250:73: warning: pointer of type 'void *' used in arithmetic [-Wpointer-arith]
Diffstat (limited to 'src/journal/journal-send.c')
-rw-r--r-- | src/journal/journal-send.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/journal/journal-send.c b/src/journal/journal-send.c index bd8f8872c9..d5ec73e371 100644 --- a/src/journal/journal-send.c +++ b/src/journal/journal-send.c @@ -246,8 +246,9 @@ _public_ int sd_journal_sendv(const struct iovec *iov, int n) { goto finish; } - have_syslog_identifier = - have_syslog_identifier || (c == iov[i].iov_base + 17 && memcmp(iov[i].iov_base, "SYSLOG_IDENTIFIER", 17) == 0); + have_syslog_identifier = have_syslog_identifier || + (c == (char *) iov[i].iov_base + 17 && + memcmp(iov[i].iov_base, "SYSLOG_IDENTIFIER", 17) == 0); nl = memchr(iov[i].iov_base, '\n', iov[i].iov_len); if (nl) { |