From 16d76e865937e900b4649c18cf1189ddf76ca1bf Mon Sep 17 00:00:00 2001 From: JD Horelick Date: Sat, 23 Oct 2010 22:32:31 -0400 Subject: [PATCH] Clang warning fixes part 2 of 2. --- src/listener.c | 2 +- src/newconf.c | 2 +- src/s_conf.c | 2 +- ssld/ssld.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/listener.c b/src/listener.c index d1351f5..b5fe775 100644 --- a/src/listener.c +++ b/src/listener.c @@ -231,7 +231,7 @@ inetport(struct Listener *listener) return 0; } - if((ret = rb_listen(F, RATBOX_SOMAXCONN))) + if(rb_listen(F, RATBOX_SOMAXCONN)) { ilog_error("listen()"); rb_close(F); diff --git a/src/newconf.c b/src/newconf.c index 761e518..597dedb 100644 --- a/src/newconf.c +++ b/src/newconf.c @@ -2020,7 +2020,7 @@ add_conf_item(const char *topconf, const char *name, int type, void (*func) (voi if((tc = find_top_conf(topconf)) == NULL) return -1; - if((cf = find_conf_item(tc, name)) != NULL) + if(find_conf_item(tc, name)) return -1; cf = rb_malloc(sizeof(struct ConfEntry)); diff --git a/src/s_conf.c b/src/s_conf.c index e09b41f..bbe7293 100644 --- a/src/s_conf.c +++ b/src/s_conf.c @@ -1768,7 +1768,7 @@ conf_fgets(char *lbuf, int max_size, FILE * fb) { char *buff; - if((buff = fgets(lbuf, max_size, fb)) == NULL) + if(fgets(lbuf, max_size, fb) == NULL) return (0); return (strlen(lbuf)); diff --git a/ssld/ssld.c b/ssld/ssld.c index a6c6b5f..9870b70 100644 --- a/ssld/ssld.c +++ b/ssld/ssld.c @@ -575,7 +575,7 @@ static void conn_mod_read_cb(rb_fde_t *fd, void *data) { conn_t *conn = data; - const char *err = remote_closed; + const char *err; int length; if(conn == NULL) return;