diff options
-rw-r--r-- | usr.sbin/smtpd/bounce.c | 16 | ||||
-rw-r--r-- | usr.sbin/smtpd/delivery_lmtp.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/dns.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/filter_api.c | 6 | ||||
-rw-r--r-- | usr.sbin/smtpd/ioev.c | 16 | ||||
-rw-r--r-- | usr.sbin/smtpd/lka_session.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/mda.c | 6 | ||||
-rw-r--r-- | usr.sbin/smtpd/mfa_session.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/mta.c | 18 | ||||
-rw-r--r-- | usr.sbin/smtpd/mta_session.c | 8 | ||||
-rw-r--r-- | usr.sbin/smtpd/parser.c | 8 | ||||
-rw-r--r-- | usr.sbin/smtpd/queue_api.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/queue_backend.c | 24 | ||||
-rw-r--r-- | usr.sbin/smtpd/queue_fs.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/scheduler_api.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/smtp_session.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/smtpd.c | 6 | ||||
-rw-r--r-- | usr.sbin/smtpd/ssl.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/table.c | 10 | ||||
-rw-r--r-- | usr.sbin/smtpd/table_api.c | 4 | ||||
-rw-r--r-- | usr.sbin/smtpd/table_passwd.c | 6 | ||||
-rw-r--r-- | usr.sbin/smtpd/table_sqlite.c | 6 | ||||
-rw-r--r-- | usr.sbin/smtpd/to.c | 10 |
23 files changed, 90 insertions, 90 deletions
diff --git a/usr.sbin/smtpd/bounce.c b/usr.sbin/smtpd/bounce.c index 4c6147374f7..39779b6e17e 100644 --- a/usr.sbin/smtpd/bounce.c +++ b/usr.sbin/smtpd/bounce.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bounce.c,v 1.57 2013/07/19 15:14:23 eric Exp $ */ +/* $OpenBSD: bounce.c,v 1.58 2013/10/26 12:27:58 eric Exp $ */ /* * Copyright (c) 2009 Gilles Chehade <gilles@poolp.org> @@ -183,7 +183,7 @@ bounce_fd(int fd) { struct bounce_session *s; - log_debug("debug: bounce: got enqueue socket %i", fd); + log_debug("debug: bounce: got enqueue socket %d", fd); if (fd == -1) { running -= 1; @@ -217,7 +217,7 @@ bounce_drain() struct timeval tv; time_t t; - log_debug("debug: bounce: drain: nmessage=%i running=%i", + log_debug("debug: bounce: drain: nmessage=%d running=%d", nmessage, running); while (1) { @@ -284,18 +284,18 @@ bounce_duration(long long int d) { static char buf[32]; if (d < 60) { - snprintf(buf, sizeof buf, "%lli second%s", d, (d == 1)?"":"s"); + snprintf(buf, sizeof buf, "%lld second%s", d, (d == 1)?"":"s"); } else if (d < 3600) { d = d / 60; - snprintf(buf, sizeof buf, "%lli minute%s", d, (d == 1)?"":"s"); + snprintf(buf, sizeof buf, "%lld minute%s", d, (d == 1)?"":"s"); } else if (d < 3600 * 24) { d = d / 3600; - snprintf(buf, sizeof buf, "%lli hour%s", d, (d == 1)?"":"s"); + snprintf(buf, sizeof buf, "%lld hour%s", d, (d == 1)?"":"s"); } else { d = d / (3600 * 24); - snprintf(buf, sizeof buf, "%lli day%s", d, (d == 1)?"":"s"); + snprintf(buf, sizeof buf, "%lld day%s", d, (d == 1)?"":"s"); } return (buf); }; @@ -638,7 +638,7 @@ bounce_io(struct io *io, int evt) break; default: - bounce_status(s, "442 i/o error %i", evt); + bounce_status(s, "442 i/o error %d", evt); bounce_free(s); break; } diff --git a/usr.sbin/smtpd/delivery_lmtp.c b/usr.sbin/smtpd/delivery_lmtp.c index 7209c663db4..be30fa82ce8 100644 --- a/usr.sbin/smtpd/delivery_lmtp.c +++ b/usr.sbin/smtpd/delivery_lmtp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: delivery_lmtp.c,v 1.2 2013/07/19 08:45:38 eric Exp $ */ +/* $OpenBSD: delivery_lmtp.c,v 1.3 2013/10/26 12:27:58 eric Exp $ */ /* * Copyright (c) 2013 Ashish SHUKLA <ashish.is@lostca.se> @@ -217,7 +217,7 @@ delivery_lmtp_open(struct deliver *deliver) break; default: - errx(1, "Bogus state %i", state); + errx(1, "Bogus state %d", state); } } diff --git a/usr.sbin/smtpd/dns.c b/usr.sbin/smtpd/dns.c index ca5337b46e4..12f0012cedc 100644 --- a/usr.sbin/smtpd/dns.c +++ b/usr.sbin/smtpd/dns.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dns.c,v 1.67 2013/07/12 14:38:34 eric Exp $ */ +/* $OpenBSD: dns.c,v 1.68 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@poolp.org> @@ -155,7 +155,7 @@ dns_imsg(struct mproc *p, struct imsg *imsg) return; default: - log_warnx("warn: bad dns request %i", s->type); + log_warnx("warn: bad dns request %d", s->type); fatal(NULL); } } diff --git a/usr.sbin/smtpd/filter_api.c b/usr.sbin/smtpd/filter_api.c index f87f8ee7abf..457d000e3ee 100644 --- a/usr.sbin/smtpd/filter_api.c +++ b/usr.sbin/smtpd/filter_api.c @@ -1,4 +1,4 @@ -/* $OpenBSD: filter_api.c,v 1.8 2013/07/19 16:02:00 eric Exp $ */ +/* $OpenBSD: filter_api.c,v 1.9 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2011 Gilles Chehade <gilles@poolp.org> @@ -325,7 +325,7 @@ filter_dispatch(struct mproc *p, struct imsg *imsg) uint64_t id, qid; int status, event, hook; - log_debug("debug: %s: imsg %i", filter_name, imsg->hdr.type); + log_debug("debug: %s: imsg %d", filter_name, imsg->hdr.type); switch (imsg->hdr.type) { case IMSG_FILTER_REGISTER: @@ -481,7 +481,7 @@ imsg_to_str(int imsg) { static char buf[32]; - snprintf(buf, sizeof(buf), "%i", imsg); + snprintf(buf, sizeof(buf), "%d", imsg); return (buf); } diff --git a/usr.sbin/smtpd/ioev.c b/usr.sbin/smtpd/ioev.c index 946ab4012b3..7468c010a47 100644 --- a/usr.sbin/smtpd/ioev.c +++ b/usr.sbin/smtpd/ioev.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ioev.c,v 1.13 2013/06/03 15:57:40 eric Exp $ */ +/* $OpenBSD: ioev.c,v 1.14 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2012 Eric Faurot <eric@openbsd.org> * @@ -88,7 +88,7 @@ io_strio(struct io *io) ssl[0] = '\0'; #ifdef IO_SSL if (io->ssl) { - snprintf(ssl, sizeof ssl, " ssl=%s:%s:%i", + snprintf(ssl, sizeof ssl, " ssl=%s:%s:%d", SSL_get_cipher_version(io->ssl), SSL_get_cipher_name(io->ssl), SSL_get_cipher_bits(io->ssl, NULL)); @@ -97,11 +97,11 @@ io_strio(struct io *io) if (io->iobuf == NULL) snprintf(buf, sizeof buf, - "<io:%p fd=%i to=%i fl=%s%s>", + "<io:%p fd=%d to=%d fl=%s%s>", io, io->sock, io->timeout, io_strflags(io->flags), ssl); else snprintf(buf, sizeof buf, - "<io:%p fd=%i to=%i fl=%s%s ib=%zu ob=%zu>", + "<io:%p fd=%d to=%d fl=%s%s ib=%zu ob=%zu>", io, io->sock, io->timeout, io_strflags(io->flags), ssl, io_pending(io), io_queued(io)); @@ -125,7 +125,7 @@ io_strevent(int evt) CASE(IO_TIMEOUT); CASE(IO_ERROR); default: - snprintf(buf, sizeof(buf), "IO_? %i", evt); + snprintf(buf, sizeof(buf), "IO_? %d", evt); return buf; } } @@ -296,7 +296,7 @@ io_release(struct io *io) void io_set_timeout(struct io *io, int msec) { - io_debug("io_set_timeout(%p, %i)\n", io, msec); + io_debug("io_set_timeout(%p, %d)\n", io, msec); io->timeout = msec; } @@ -812,7 +812,7 @@ again: io_callback(io, IO_ERROR); break; default: - io_debug("io_dispatch_read_ssl(...) -> r=%i\n", n); + io_debug("io_dispatch_read_ssl(...) -> r=%d\n", n); io_callback(io, IO_DATAIN); if (current == io && IO_READING(io) && SSL_pending(io->ssl)) goto again; @@ -859,7 +859,7 @@ io_dispatch_write_ssl(int fd, short event, void *humppa) io_callback(io, IO_ERROR); break; default: - io_debug("io_dispatch_write_ssl(...) -> w=%i\n", n); + io_debug("io_dispatch_write_ssl(...) -> w=%d\n", n); w2 = io_queued(io); if (w > io->lowat && w2 <= io->lowat) io_callback(io, IO_LOWAT); diff --git a/usr.sbin/smtpd/lka_session.c b/usr.sbin/smtpd/lka_session.c index 95aaa3f4a60..e2d97819dbe 100644 --- a/usr.sbin/smtpd/lka_session.c +++ b/usr.sbin/smtpd/lka_session.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lka_session.c,v 1.57 2013/07/19 08:12:19 eric Exp $ */ +/* $OpenBSD: lka_session.c,v 1.58 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2011 Gilles Chehade <gilles@poolp.org> @@ -420,7 +420,7 @@ lka_find_ancestor(struct expandnode *xn, enum expand_type type) while (xn && (xn->type != type)) xn = xn->parent; if (xn == NULL) { - log_warnx("warn: lka_find_ancestor: no ancestors of type %i", + log_warnx("warn: lka_find_ancestor: no ancestors of type %d", type); fatalx(NULL); } diff --git a/usr.sbin/smtpd/mda.c b/usr.sbin/smtpd/mda.c index b7b9eac4a19..79c81fb3612 100644 --- a/usr.sbin/smtpd/mda.c +++ b/usr.sbin/smtpd/mda.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mda.c,v 1.94 2013/07/19 15:14:23 eric Exp $ */ +/* $OpenBSD: mda.c,v 1.95 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@poolp.org> @@ -270,7 +270,7 @@ mda_imsg(struct mproc *p, struct imsg *imsg) return; } - log_debug("debug: mda: got message fd %i " + log_debug("debug: mda: got message fd %d " "for session %016"PRIx64 " evpid %016"PRIx64, imsg->fd, s->id, e->id); @@ -401,7 +401,7 @@ mda_imsg(struct mproc *p, struct imsg *imsg) return; } - log_debug("debug: mda: got mda fd %i " + log_debug("debug: mda: got mda fd %d " "for session %016"PRIx64 " evpid %016"PRIx64, imsg->fd, s->id, s->evp->id); diff --git a/usr.sbin/smtpd/mfa_session.c b/usr.sbin/smtpd/mfa_session.c index bcc1a108faf..2c212b6baba 100644 --- a/usr.sbin/smtpd/mfa_session.c +++ b/usr.sbin/smtpd/mfa_session.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mfa_session.c,v 1.18 2013/07/19 16:02:00 eric Exp $ */ +/* $OpenBSD: mfa_session.c,v 1.19 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2011 Gilles Chehade <gilles@poolp.org> @@ -378,7 +378,7 @@ mfa_drain_query(struct mfa_query *q) log_trace(TRACE_MFA, "filter: query 0x%016"PRIx64" done: " - "status=%s code=%i response=\"%s\"", + "status=%s code=%d response=\"%s\"", q->qid, status_to_str(q->smtp.status), q->smtp.code, diff --git a/usr.sbin/smtpd/mta.c b/usr.sbin/smtpd/mta.c index 9b8a8c93e8e..1566d91872f 100644 --- a/usr.sbin/smtpd/mta.c +++ b/usr.sbin/smtpd/mta.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mta.c,v 1.163 2013/07/19 21:14:52 eric Exp $ */ +/* $OpenBSD: mta.c,v 1.164 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org> @@ -294,7 +294,7 @@ mta_imsg(struct mproc *p, struct imsg *imsg) log_debug("debug: MXs for domain %s:", domain->name); TAILQ_FOREACH(mx, &domain->mxs, entry) - log_debug(" %s preference %i", + log_debug(" %s preference %d", sa_to_text(mx->host->sa), mx->preference); } @@ -372,7 +372,7 @@ mta_imsg(struct mproc *p, struct imsg *imsg) SPLAY_FOREACH(route, mta_route_tree, &routes) { v = runq_pending(runq_route, NULL, route, &t); snprintf(buf, sizeof(buf), - "%llu. %s %c%c%c%c nconn=%zu penalty=%i timeout=%s", + "%llu. %s %c%c%c%c nconn=%zu penalty=%d timeout=%s", (unsigned long long)route->id, mta_route_to_text(route), route->flags & ROUTE_NEW ? 'N' : '-', @@ -835,7 +835,7 @@ mta_on_preference(struct mta_relay *relay, int dnserror, int preference) relay->backuppref = INT_MAX; } else { - log_debug("debug: mta: ... got preference for %s: %i, %i", + log_debug("debug: mta: ... got preference for %s: %d, %d", mta_relay_to_text(relay), dnserror, preference); relay->backuppref = preference; } @@ -1131,7 +1131,7 @@ mta_drain(struct mta_relay *r) char buf[64]; log_debug("debug: mta: draining %s " - "refcount=%i, ntask=%zu, nconnector=%zu, nconn=%zu", + "refcount=%d, ntask=%zu, nconnector=%zu, nconn=%zu", mta_relay_to_text(r), r->refcount, r->ntask, tree_count(&r->connectors), r->nconn); @@ -1211,11 +1211,11 @@ mta_flush(struct mta_relay *relay, int fail, const char *error) size_t n; size_t r; - log_debug("debug: mta_flush(%s, %i, \"%s\")", + log_debug("debug: mta_flush(%s, %d, \"%s\")", mta_relay_to_text(relay), fail, error); if (fail != IMSG_DELIVERY_TEMPFAIL && fail != IMSG_DELIVERY_PERMFAIL) - errx(1, "unexpected delivery status %i", fail); + errx(1, "unexpected delivery status %d", fail); n = 0; while ((task = TAILQ_FIRST(&relay->tasks))) { @@ -1576,7 +1576,7 @@ mta_relay_to_text(struct mta_relay *relay) if (relay->port) { strlcat(buf, sep, sizeof buf); - snprintf(tmp, sizeof tmp, "port=%i", (int)relay->port); + snprintf(tmp, sizeof tmp, "port=%d", (int)relay->port); strlcat(buf, tmp, sizeof buf); } @@ -1987,7 +1987,7 @@ mta_route_unref(struct mta_route *r) if (delay > DELAY_ROUTE_MAX) delay = DELAY_ROUTE_MAX; sched = r->lastpenalty + delay; - log_debug("debug: mta: mta_route_unref(): keeping route %s alive for %llus (penalty %i)", + log_debug("debug: mta: mta_route_unref(): keeping route %s alive for %llus (penalty %d)", mta_route_to_text(r), (unsigned long long) sched - now, r->penalty); } else if (!(r->flags & ROUTE_KEEPALIVE)) { if (r->lastconn + max_seen_conndelay_route > now) diff --git a/usr.sbin/smtpd/mta_session.c b/usr.sbin/smtpd/mta_session.c index fa5ce1cd808..985aee5145e 100644 --- a/usr.sbin/smtpd/mta_session.c +++ b/usr.sbin/smtpd/mta_session.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mta_session.c,v 1.41 2013/10/25 14:21:06 deraadt Exp $ */ +/* $OpenBSD: mta_session.c,v 1.42 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org> @@ -544,7 +544,7 @@ mta_connect(struct mta_session *s) else schema = "smtp://"; - log_info("smtp-out: Connecting to %s%s:%i (%s) on session" + log_info("smtp-out: Connecting to %s%s:%d (%s) on session" " %016"PRIx64"...", schema, sa_to_text(s->route->dst->sa), portno, s->route->dst->ptrname, s->id); @@ -970,7 +970,7 @@ mta_response(struct mta_session *s, char *line) } else { s->rcptcount = 0; if (s->relay->limits->sessdelay_transaction) { - log_debug("debug: mta: waiting for %llis before next transaction", + log_debug("debug: mta: waiting for %llds before next transaction", (long long int)s->relay->limits->sessdelay_transaction); s->hangon = s->relay->limits->sessdelay_transaction -1; s->flags |= MTA_HANGON; @@ -987,7 +987,7 @@ mta_response(struct mta_session *s, char *line) mta_flush_failedqueue(s); s->rcptcount = 0; if (s->relay->limits->sessdelay_transaction) { - log_debug("debug: mta: waiting for %llis after reset", + log_debug("debug: mta: waiting for %llds after reset", (long long int)s->relay->limits->sessdelay_transaction); s->hangon = s->relay->limits->sessdelay_transaction -1; s->flags |= MTA_HANGON; diff --git a/usr.sbin/smtpd/parser.c b/usr.sbin/smtpd/parser.c index aea11b37921..0c8d12db11d 100644 --- a/usr.sbin/smtpd/parser.c +++ b/usr.sbin/smtpd/parser.c @@ -1,4 +1,4 @@ -/* $OpenBSD: parser.c,v 1.36 2013/10/25 18:58:10 eric Exp $ */ +/* $OpenBSD: parser.c,v 1.37 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot <eric@openbsd.org> @@ -165,7 +165,7 @@ cmd_check(const char *str, struct node *node, struct parameter *res) return (1); default: - errx(1, "bad token type: %i", node->type); + errx(1, "bad token type: %d", node->type); return (0); } } @@ -239,7 +239,7 @@ cmd_show_params(int argc, struct parameter *argv) printf(" str:\"%s\"", argv[i].u.u_str); break; case P_INT: - printf(" int:%i", argv[i].u.u_int); + printf(" int:%d", argv[i].u.u_int); break; case P_MSGID: printf(" msgid:%08"PRIx32, argv[i].u.u_msgid); @@ -251,7 +251,7 @@ cmd_show_params(int argc, struct parameter *argv) printf(" routeid:%016"PRIx64, argv[i].u.u_routeid); break; default: - printf(" ???:%i", argv[i].type); + printf(" ???:%d", argv[i].type); } } printf ("\n"); diff --git a/usr.sbin/smtpd/queue_api.c b/usr.sbin/smtpd/queue_api.c index adde88bdc64..6484c3578fa 100644 --- a/usr.sbin/smtpd/queue_api.c +++ b/usr.sbin/smtpd/queue_api.c @@ -1,4 +1,4 @@ -/* $OpenBSD: queue_api.c,v 1.1 2013/07/19 20:37:07 eric Exp $ */ +/* $OpenBSD: queue_api.c,v 1.2 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot <eric@openbsd.org> @@ -243,7 +243,7 @@ queue_msg_dispatch(void) queue_msg_close(); default: - log_warnx("warn: queue-api: bad message %i", imsg.hdr.type); + log_warnx("warn: queue-api: bad message %d", imsg.hdr.type); fatalx("queue-api: exiting"); } } diff --git a/usr.sbin/smtpd/queue_backend.c b/usr.sbin/smtpd/queue_backend.c index e52d6a07afc..a1e7acc3bab 100644 --- a/usr.sbin/smtpd/queue_backend.c +++ b/usr.sbin/smtpd/queue_backend.c @@ -1,4 +1,4 @@ -/* $OpenBSD: queue_backend.c,v 1.46 2013/07/19 20:37:07 eric Exp $ */ +/* $OpenBSD: queue_backend.c,v 1.47 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2011 Gilles Chehade <gilles@poolp.org> @@ -93,7 +93,7 @@ static inline void profile_leave(void) clock_gettime(CLOCK_MONOTONIC, &t1); timespecsub(&t1, &profile.t0, &dt); - log_debug("profile-queue: %s %lld.%06li", profile.name, + log_debug("profile-queue: %s %lld.%06ld", profile.name, (long long)dt.tv_sec * 1000000 + dt.tv_nsec / 1000000, dt.tv_nsec % 1000000); } @@ -153,7 +153,7 @@ queue_init(const char *name, int server) r = backend->init(pwq, server); - log_trace(TRACE_QUEUE, "queue-backend: queue_init(%i) -> %i", server, r); + log_trace(TRACE_QUEUE, "queue-backend: queue_init(%d) -> %d", server, r); return (r); } @@ -168,7 +168,7 @@ queue_message_create(uint32_t *msgid) profile_leave(); log_trace(TRACE_QUEUE, - "queue-backend: queue_message_create() -> %i (%08"PRIx32")", + "queue-backend: queue_message_create() -> %d (%08"PRIx32")", r, *msgid); return (r); @@ -189,7 +189,7 @@ queue_message_delete(uint32_t msgid) unlink(msgpath); log_trace(TRACE_QUEUE, - "queue-backend: queue_message_delete(%08"PRIx32") -> %i", msgid, r); + "queue-backend: queue_message_delete(%08"PRIx32") -> %d", msgid, r); return (r); } @@ -258,7 +258,7 @@ queue_message_commit(uint32_t msgid) unlink(msgpath); log_trace(TRACE_QUEUE, - "queue-backend: queue_message_commit(%08"PRIx32") -> %i", + "queue-backend: queue_message_commit(%08"PRIx32") -> %d", msgid, r); return (r); @@ -281,7 +281,7 @@ queue_message_corrupt(uint32_t msgid) profile_leave(); log_trace(TRACE_QUEUE, - "queue-backend: queue_message_corrupt(%08"PRIx32") -> %i", msgid, r); + "queue-backend: queue_message_corrupt(%08"PRIx32") -> %d", msgid, r); return (r); } @@ -298,7 +298,7 @@ queue_message_fd_r(uint32_t msgid) profile_leave(); log_trace(TRACE_QUEUE, - "queue-backend: queue_message_fd_r(%08"PRIx32") -> %i", msgid, fdin); + "queue-backend: queue_message_fd_r(%08"PRIx32") -> %d", msgid, fdin); if (fdin == -1) return (-1); @@ -503,7 +503,7 @@ queue_envelope_create(struct envelope *ep) profile_leave(); log_trace(TRACE_QUEUE, - "queue-backend: queue_envelope_create(%016"PRIx64", %zu) -> %i (%016"PRIx64")", + "queue-backend: queue_envelope_create(%016"PRIx64", %zu) -> %d (%016"PRIx64")", evpid, evplen, r, ep->id); if (!r) { @@ -530,7 +530,7 @@ queue_envelope_delete(uint64_t evpid) profile_leave(); log_trace(TRACE_QUEUE, - "queue-backend: queue_envelope_delete(%016"PRIx64") -> %i", + "queue-backend: queue_envelope_delete(%016"PRIx64") -> %d", evpid, r); return (r); @@ -599,7 +599,7 @@ queue_envelope_update(struct envelope *ep) queue_envelope_cache_update(ep); log_trace(TRACE_QUEUE, - "queue-backend: queue_envelope_update(%016"PRIx64") -> %i", + "queue-backend: queue_envelope_update(%016"PRIx64") -> %d", ep->id, r); return (r); @@ -618,7 +618,7 @@ queue_envelope_walk(struct envelope *ep) profile_leave(); log_trace(TRACE_QUEUE, - "queue-backend: queue_envelope_walk() -> %i (%016"PRIx64")", + "queue-backend: queue_envelope_walk() -> %d (%016"PRIx64")", r, evpid); if (r == -1) diff --git a/usr.sbin/smtpd/queue_fs.c b/usr.sbin/smtpd/queue_fs.c index 767064172ac..5530312d726 100644 --- a/usr.sbin/smtpd/queue_fs.c +++ b/usr.sbin/smtpd/queue_fs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: queue_fs.c,v 1.1 2013/07/19 20:37:07 eric Exp $ */ +/* $OpenBSD: queue_fs.c,v 1.2 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2011 Gilles Chehade <gilles@poolp.org> @@ -215,7 +215,7 @@ again: if (stat(corruptdir, &sb) != -1 || errno != ENOENT) { fsqueue_message_corrupt_path(msgid, corruptdir, sizeof(corruptdir)); - snprintf(buf, sizeof(buf), ".%i", retry++); + snprintf(buf, sizeof(buf), ".%d", retry++); strlcat(corruptdir, buf, sizeof(corruptdir)); goto again; } diff --git a/usr.sbin/smtpd/scheduler_api.c b/usr.sbin/smtpd/scheduler_api.c index 6f0b214d798..87300433853 100644 --- a/usr.sbin/smtpd/scheduler_api.c +++ b/usr.sbin/smtpd/scheduler_api.c @@ -1,4 +1,4 @@ -/* $OpenBSD: scheduler_api.c,v 1.1 2013/07/19 21:34:31 eric Exp $ */ +/* $OpenBSD: scheduler_api.c,v 1.2 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot <eric@openbsd.org> @@ -271,7 +271,7 @@ scheduler_msg_dispatch(void) break; default: - log_warnx("warn: scheduler-api: bad message %i", imsg.hdr.type); + log_warnx("warn: scheduler-api: bad message %d", imsg.hdr.type); fatalx("scheduler-api: exiting"); } } diff --git a/usr.sbin/smtpd/smtp_session.c b/usr.sbin/smtpd/smtp_session.c index 354f7e299c4..d0a91444bcb 100644 --- a/usr.sbin/smtpd/smtp_session.c +++ b/usr.sbin/smtpd/smtp_session.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smtp_session.c,v 1.184 2013/07/19 21:18:54 eric Exp $ */ +/* $OpenBSD: smtp_session.c,v 1.185 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@poolp.org> @@ -1387,7 +1387,7 @@ smtp_message_end(struct smtp_session *s) if (s->msgflags & MF_ERROR_SIZE) smtp_reply(s, "554 Message too big"); else - smtp_reply(s, "%i Message rejected", s->msgcode); + smtp_reply(s, "%d Message rejected", s->msgcode); smtp_message_reset(s, 0); smtp_enter_state(s, STATE_HELO); return; diff --git a/usr.sbin/smtpd/smtpd.c b/usr.sbin/smtpd/smtpd.c index 94d40fb919c..ef402981bfb 100644 --- a/usr.sbin/smtpd/smtpd.c +++ b/usr.sbin/smtpd/smtpd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smtpd.c,v 1.198 2013/07/19 21:58:54 eric Exp $ */ +/* $OpenBSD: smtpd.c,v 1.199 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@poolp.org> @@ -1305,7 +1305,7 @@ imsg_dispatch(struct mproc *p, struct imsg *imsg) clock_gettime(CLOCK_MONOTONIC, &t1); timespecsub(&t1, &t0, &dt); - log_debug("profile-imsg: %s %s %s %i %lld.%06li", + log_debug("profile-imsg: %s %s %s %d %lld.%06ld", proc_name(smtpd_process), proc_name(p->proc), imsg_to_str(imsg->hdr.type), @@ -1338,7 +1338,7 @@ log_imsg(int to, int from, struct imsg *imsg) return; if (imsg->fd != -1) - log_trace(TRACE_IMSG, "imsg: %s <- %s: %s (len=%zu, fd=%i)", + log_trace(TRACE_IMSG, "imsg: %s <- %s: %s (len=%zu, fd=%d)", proc_name(to), proc_name(from), imsg_to_str(imsg->hdr.type), diff --git a/usr.sbin/smtpd/ssl.c b/usr.sbin/smtpd/ssl.c index 31a9970da8c..f7559a5abab 100644 --- a/usr.sbin/smtpd/ssl.c +++ b/usr.sbin/smtpd/ssl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl.c,v 1.54 2013/07/19 09:04:06 eric Exp $ */ +/* $OpenBSD: ssl.c,v 1.55 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org> @@ -309,7 +309,7 @@ ssl_to_text(const SSL *ssl) { static char buf[256]; - snprintf(buf, sizeof buf, "version=%s, cipher=%s, bits=%i", + snprintf(buf, sizeof buf, "version=%s, cipher=%s, bits=%d", SSL_get_cipher_version(ssl), SSL_get_cipher_name(ssl), SSL_get_cipher_bits(ssl, NULL)); diff --git a/usr.sbin/smtpd/table.c b/usr.sbin/smtpd/table.c index 45e4210edb0..5790035f69e 100644 --- a/usr.sbin/smtpd/table.c +++ b/usr.sbin/smtpd/table.c @@ -1,4 +1,4 @@ -/* $OpenBSD: table.c,v 1.7 2013/07/20 09:06:46 eric Exp $ */ +/* $OpenBSD: table.c,v 1.8 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot <eric@openbsd.org> @@ -143,7 +143,7 @@ table_lookup(struct table *table, const char *key, enum table_service kind, (lk) ? table_dump_lookup(kind, lk): "found", lk ? "\"" : ""); else - log_trace(TRACE_LOOKUP, "lookup: %s \"%s\" as %s in table %s:%s -> %i", + log_trace(TRACE_LOOKUP, "lookup: %s \"%s\" as %s in table %s:%s -> %d", lk ? "lookup" : "check", lkey, table_service_name(kind), @@ -173,7 +173,7 @@ table_fetch(struct table *table, enum table_service kind, union lookup *lk) (lk) ? table_dump_lookup(kind, lk): "found", lk ? "\"" : ""); else - log_trace(TRACE_LOOKUP, "lookup: fetch %s from table %s:%s -> %i", + log_trace(TRACE_LOOKUP, "lookup: fetch %s from table %s:%s -> %d", table_service_name(kind), table_backend_name(table->t_backend), table->t_name, @@ -639,13 +639,13 @@ table_dump_lookup(enum table_service s, union lookup *lk) break; case K_NETADDR: - snprintf(buf, sizeof(buf), "%s/%i", + snprintf(buf, sizeof(buf), "%s/%d", sockaddr_to_text((struct sockaddr *)&lk->netaddr.ss), lk->netaddr.bits); break; case K_USERINFO: - snprintf(buf, sizeof(buf), "%s:%i:%i:%s", + snprintf(buf, sizeof(buf), "%s:%d:%d:%s", lk->userinfo.username, lk->userinfo.uid, lk->userinfo.gid, diff --git a/usr.sbin/smtpd/table_api.c b/usr.sbin/smtpd/table_api.c index 93ba00ecc41..e2ad7339f2d 100644 --- a/usr.sbin/smtpd/table_api.c +++ b/usr.sbin/smtpd/table_api.c @@ -1,4 +1,4 @@ -/* $OpenBSD: table_api.c,v 1.2 2013/07/20 09:06:46 eric Exp $ */ +/* $OpenBSD: table_api.c,v 1.3 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot <eric@openbsd.org> @@ -199,7 +199,7 @@ table_msg_dispatch(void) break; default: - log_warnx("warn: table-api: bad message %i", imsg.hdr.type); + log_warnx("warn: table-api: bad message %d", imsg.hdr.type); fatalx("table-api: exiting"); } } diff --git a/usr.sbin/smtpd/table_passwd.c b/usr.sbin/smtpd/table_passwd.c index dcc9bb7e3ac..baca7792470 100644 --- a/usr.sbin/smtpd/table_passwd.c +++ b/usr.sbin/smtpd/table_passwd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: table_passwd.c,v 1.3 2013/10/24 20:07:16 eric Exp $ */ +/* $OpenBSD: table_passwd.c,v 1.4 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Gilles Chehade <gilles@poolp.org> @@ -174,7 +174,7 @@ table_passwd_lookup(int service, const char *key, char *dst, size_t sz) } break; case K_USERINFO: - if (snprintf(dst, sz, "%i:%i:%s", + if (snprintf(dst, sz, "%d:%d:%s", pw.pw_uid, pw.pw_gid, pw.pw_dir) > (ssize_t)sz) { log_warnx("warn: table-passwd: result too large"); @@ -182,7 +182,7 @@ table_passwd_lookup(int service, const char *key, char *dst, size_t sz) } break; default: - log_warnx("warn: table-passwd: unknown service %i", + log_warnx("warn: table-passwd: unknown service %d", service); r = -1; } diff --git a/usr.sbin/smtpd/table_sqlite.c b/usr.sbin/smtpd/table_sqlite.c index 870341ac81d..f2e91f08df8 100644 --- a/usr.sbin/smtpd/table_sqlite.c +++ b/usr.sbin/smtpd/table_sqlite.c @@ -1,4 +1,4 @@ -/* $OpenBSD: table_sqlite.c,v 1.7 2013/10/24 20:26:45 eric Exp $ */ +/* $OpenBSD: table_sqlite.c,v 1.8 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot <eric@openbsd.org> @@ -450,7 +450,7 @@ table_sqlite_lookup(int service, const char *key, char *dst, size_t sz) } break; case K_USERINFO: - if (snprintf(dst, sz, "%i:%i:%s", + if (snprintf(dst, sz, "%d:%d:%s", sqlite3_column_int(stmt, 0), sqlite3_column_int(stmt, 1), sqlite3_column_text(stmt, 2)) > (ssize_t)sz) { @@ -469,7 +469,7 @@ table_sqlite_lookup(int service, const char *key, char *dst, size_t sz) } break; default: - log_warnx("warn: table-sqlite: unknown service %i", service); + log_warnx("warn: table-sqlite: unknown service %d", service); r = -1; } diff --git a/usr.sbin/smtpd/to.c b/usr.sbin/smtpd/to.c index f1189e80f89..9efacef5dc9 100644 --- a/usr.sbin/smtpd/to.c +++ b/usr.sbin/smtpd/to.c @@ -1,4 +1,4 @@ -/* $OpenBSD: to.c,v 1.8 2013/07/19 16:02:00 eric Exp $ */ +/* $OpenBSD: to.c,v 1.9 2013/10/26 12:27:59 eric Exp $ */ /* * Copyright (c) 2009 Jacek Masiulaniec <jacekm@dobremiasto.net> @@ -240,19 +240,19 @@ duration_to_text(time_t t) d = t / 24; if (d) { - snprintf(buf, sizeof buf, "%llid", d); + snprintf(buf, sizeof buf, "%lldd", d); strlcat(dst, buf, sizeof dst); } if (h) { - snprintf(buf, sizeof buf, "%ih", h); + snprintf(buf, sizeof buf, "%dh", h); strlcat(dst, buf, sizeof dst); } if (m) { - snprintf(buf, sizeof buf, "%im", m); + snprintf(buf, sizeof buf, "%dm", m); strlcat(dst, buf, sizeof dst); } if (s) { - snprintf(buf, sizeof buf, "%is", s); + snprintf(buf, sizeof buf, "%ds", s); strlcat(dst, buf, sizeof dst); } |