diff --git a/cli-main.c b/cli-main.c
index 9506759da5a48af6826350e55d6e4110c0f59cd6..3cfc02d65c110f2fd84985d66963024d71676de1 100644
--- a/cli-main.c
+++ b/cli-main.c
@@ -164,11 +164,11 @@ static void cli_proxy_cmd(int *sock_in, int *sock_out, pid_t *pid_out) {
 	}
 }
 
-static void killchild(int signo)
-{
+static void killchild(int signo) {
 	kill_proxy_command();
-	if (signo)
+	if (signo) {
 		_exit(1);
+	}
 	exit(1);
 }
 #endif /* ENABLE_CLI_PROXYCMD */
diff --git a/cli-runopts.c b/cli-runopts.c
index 3c70332aae05945024c721ae2f0f2e4143bb2380..fad9428d129901cb91f83aac3b47c6f58eb07a7d 100644
--- a/cli-runopts.c
+++ b/cli-runopts.c
@@ -828,17 +828,20 @@ static int match_extendedopt(const char** strptr, const char *optname) {
 	int optlen = strlen(optname);
 	const char *str = *strptr;
 
-	while (isspace(*str))
+	while (isspace(*str)) {
 		++str;
+	}
 
-	if (strncasecmp(str, optname, optlen) != 0)
+	if (strncasecmp(str, optname, optlen) != 0) {
 		return DROPBEAR_FAILURE;
+	}
 
 	str += optlen;
 
 	while (isspace(*str) || (!seen_eq && *str == '=')) {
-		if (*str == '=')
+		if (*str == '=') {
 			seen_eq = 1;
+		}
 		++str;
 	}
 
@@ -846,12 +849,12 @@ static int match_extendedopt(const char** strptr, const char *optname) {
 	return DROPBEAR_SUCCESS;
 }
 
-static int parse_flag_value(const char *value)
-{
-	if (strcmp(value, "yes") == 0 || strcmp(value, "true") == 0)
+static int parse_flag_value(const char *value) {
+	if (strcmp(value, "yes") == 0 || strcmp(value, "true") == 0) {
 		return 1;
-	else if (strcmp(value, "no") == 0 || strcmp(value, "false") == 0)
+	} else if (strcmp(value, "no") == 0 || strcmp(value, "false") == 0) {
 		return 0;
+	}
 
 	dropbear_exit("Bad yes/no argument '%s'", value);
 }
diff --git a/cli-tcpfwd.c b/cli-tcpfwd.c
index 4d46b94e58c3da304c57fabd5814fdb769fab248..fec5dbaaef89f7f790bfedb636641a0bb83b4d82 100644
--- a/cli-tcpfwd.c
+++ b/cli-tcpfwd.c
@@ -67,10 +67,11 @@ void fwd_failed(const char* format, ...)
 	va_list param;
 	va_start(param, format);
 
-	if (cli_opts.exit_on_fwd_failure)
+	if (cli_opts.exit_on_fwd_failure) {
 		_dropbear_exit(EXIT_FAILURE, format, param);
-	else
+	} else {
 		_dropbear_log(LOG_WARNING, format, param);
+	}
 
 	va_end(param);
 }
diff --git a/session.h b/session.h
index 08995732a03b5490564d5be15c473d73a9854cf0..77e1bcd8d6c5c4d97312b95664cf78208dbaf26e 100644
--- a/session.h
+++ b/session.h
@@ -305,7 +305,7 @@ struct clientsession {
 	struct AgentkeyList *agentkeys; /* Keys to use for public-key auth */
 #endif
 
-	int proxy_cmd_pid;
+	pid_t proxy_cmd_pid;
 };
 
 /* Global structs storing the state */
diff --git a/svr-session.c b/svr-session.c
index c3785626df192428f51435ff0fc7682a099ac53b..f777b5f3ae566b7a065adb49ebb7056cbc659a6d 100644
--- a/svr-session.c
+++ b/svr-session.c
@@ -215,8 +215,7 @@ void svr_dropbear_log(int priority, const char* format, va_list param) {
 	havetrace = debug_trace;
 #endif
 
-	if (!opts.usingsyslog || havetrace)
-	{
+	if (!opts.usingsyslog || havetrace) {
 		struct tm * local_tm = NULL;
 		timesec = time(NULL);
 		local_tm = localtime(&timesec);