commit - 4574fbd094b0b258d32078f6feb25547df97a8de
commit + 6258daeb86bb3ab929666d176f9fdb95dd6fd822
blob - 2eaa14e61a0d7ee3891732a2843c21671c18fbf9
blob + abd74f4d4aa1f11bfea7981ea702ecd3fab1dad6
--- opensmtpd.c
+++ opensmtpd.c
}
static void
-osmtpd_newline(struct io *io, int ev, void *arg)
+osmtpd_newline(struct io *io, int ev, __unused void *arg)
{
static char *linedup = NULL;
static size_t dupsize = 0;
}
static void
-osmtpd_outevt(struct io *io, int evt, void *arg)
+osmtpd_outevt(__unused struct io *io, int evt, __unused void *arg)
{
switch (evt) {
case IO_LOWAT:
}
static void
-osmtpd_noargs(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx, char *params,
- char *linedup)
+osmtpd_noargs(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx,
+ __unused char *params, __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *);
static void
osmtpd_onearg(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx, char *line,
- char *linedup)
+ __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *, const char *);
static void
osmtpd_identify(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx,
- char *identity, char *linedup)
+ char *identity, __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *, const char *);
static void
osmtpd_link_disconnect(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx,
- char *param, char *linedup)
+ __unused char *param, __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *);
size_t i;
static void
osmtpd_link_greeting(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx,
- char *identity, char *linedup)
+ char *identity, __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *, const char *);
static void
osmtpd_link_identify(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx,
- char *identity, char *linedup)
+ char *identity, __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *, const char *);
static void
osmtpd_link_tls(struct osmtpd_callback *cb, struct osmtpd_ctx *ctx,
- char *ciphers, char *linedup)
+ char *ciphers, __unused char *linedup)
{
void (*f)(struct osmtpd_ctx *, const char *);
if (addr[0] == '[') {
sin6 = (struct sockaddr_in6 *)ss;
- sin6->sin6_len = sizeof(*sin6);
sin6->sin6_family = AF_INET6;
sin6->sin6_port = 0;
if (hasport) {
}
} else if (strncasecmp(addr, "unix:", 5) == 0) {
sun = (struct sockaddr_un *)ss;
- sun->sun_len = sizeof(*sun);
sun->sun_family = AF_UNIX;
if (strlcpy(sun->sun_path, addr,
sizeof(sun->sun_path)) >= sizeof(sun->sun_path)) {
}
} else {
sin = (struct sockaddr_in *)ss;
- sin->sin_len = sizeof(*sin);
sin->sin_family = AF_INET;
sin->sin_port = 0;
if (hasport) {
blob - 9a58a8d8764b383d3e902c5ee51f806f44b3552b
blob + 26546428978f8cb26810f3fb5620e67180f3ba0f
--- opensmtpd.h
+++ opensmtpd.h
*/
#include <sys/socket.h>
+#ifndef __dead
+#define __dead __attribute__((__noreturn__))
+#endif
+#ifndef __unused
+#define __unused __attribute__((unused))
+#endif
+
enum osmtpd_status {
OSMTPD_STATUS_OK,
OSMTPD_STATUS_TEMPFAIL,