# SURBL module params, note that single quotes are mandatory here
.module 'surbl' {
# Address to redirector in host:port format
- #redirector = "localhost:8080";
+ redirector = "localhost:8080";
# Connect timeout for redirector
redirector_connect_timeout = "1s";
# IO timeout for redirector (may be usefull to set this value rather big)
bzero (&sc, sizeof (struct sockaddr_in *));
sc.sin_family = AF_INET;
- sc.sin_port = htonl (surbl_module_ctx->redirector_port);
+ sc.sin_port = htons (surbl_module_ctx->redirector_port);
memcpy (&sc.sin_addr, &surbl_module_ctx->redirector_addr, sizeof (struct in_addr));
s = socket (PF_INET, SOCK_STREAM, 0);
}
/* set nonblocking */
- ofl = fcntl(s, F_GETFL, 0);
- fcntl(s, F_SETFL, ofl | O_NONBLOCK);
+ ofl = fcntl (s, F_GETFL, 0);
+ fcntl (s, F_SETFL, ofl | O_NONBLOCK);
if ((r = connect (s, (struct sockaddr*)&sc, sizeof (struct sockaddr_in))) == -1) {
if (errno != EINPROGRESS) {