Mercurial > dropbear
diff svr-chansession.c @ 1129:45830474d83c coverity
merge up to date, attempt to fix travis.yml
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Fri, 12 Jun 2015 23:02:15 +0800 |
parents | aaf576b27a10 |
children | b1fabf797bd3 |
line wrap: on
line diff
--- a/svr-chansession.c Tue Apr 14 20:44:30 2015 +0800 +++ b/svr-chansession.c Fri Jun 12 23:02:15 2015 +0800 @@ -343,7 +343,7 @@ * or x11/authagent forwarding. These are passed to appropriate handlers */ static void chansessionrequest(struct Channel *channel) { - unsigned char * type = NULL; + char * type = NULL; unsigned int typelen; unsigned char wantreply; int ret = 1; @@ -406,7 +406,7 @@ static int sessionsignal(struct ChanSess *chansess) { int sig = 0; - unsigned char* signame = NULL; + char* signame = NULL; int i; if (chansess->pid == 0) { @@ -557,7 +557,7 @@ static int sessionpty(struct ChanSess * chansess) { unsigned int termlen; - unsigned char namebuf[65]; + char namebuf[65]; struct passwd * pw = NULL; TRACE(("enter sessionpty")) @@ -583,7 +583,7 @@ return DROPBEAR_FAILURE; } - chansess->tty = (char*)m_strdup(namebuf); + chansess->tty = m_strdup(namebuf); if (!chansess->tty) { dropbear_exit("Out of memory"); /* TODO disconnect */ } @@ -603,6 +603,7 @@ return DROPBEAR_SUCCESS; } +#ifndef USE_VFORK static void make_connection_string(struct ChanSess *chansess) { char *local_ip, *local_port, *remote_ip, *remote_port; size_t len; @@ -624,6 +625,7 @@ m_free(remote_ip); m_free(remote_port); } +#endif /* Handle a command request from the client. This is used for both shell * and command-execution requests, and passes the command to