summaryrefslogtreecommitdiffhomepage
path: root/cli-chansession.c
diff options
context:
space:
mode:
authorFrancois Perrad <francois.perrad@gadz.org>2017-08-19 22:39:53 +0200
committerFrancois Perrad <francois.perrad@gadz.org>2017-08-19 22:39:53 +0200
commit598056d1686127285c389cacbdd20707c350d05a (patch)
treed821ca44d56c707bd3e6fe35f5cb58ff6eb1ccda /cli-chansession.c
parent89e64c631ec8dee41ec4de888548d36887b6ec98 (diff)
Pointer parameter could be declared as pointing to const (callback)
Diffstat (limited to 'cli-chansession.c')
-rw-r--r--cli-chansession.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/cli-chansession.c b/cli-chansession.c
index d190b20..ded9eac 100644
--- a/cli-chansession.c
+++ b/cli-chansession.c
@@ -35,12 +35,12 @@
#include "chansession.h"
#include "agentfwd.h"
-static void cli_closechansess(struct Channel *channel);
+static void cli_closechansess(const struct Channel *channel);
static int cli_initchansess(struct Channel *channel);
static void cli_chansessreq(struct Channel *channel);
static void send_chansess_pty_req(const struct Channel *channel);
static void send_chansess_shell_req(const struct Channel *channel);
-static void cli_escape_handler(struct Channel *channel, unsigned char* buf, int *len);
+static void cli_escape_handler(const struct Channel *channel, const unsigned char* buf, int *len);
static int cli_init_netcat(struct Channel *channel);
static void cli_tty_setup(void);
@@ -83,7 +83,7 @@ out:
/* If the main session goes, we close it up */
-static void cli_closechansess(struct Channel *UNUSED(channel)) {
+static void cli_closechansess(const struct Channel *UNUSED(channel)) {
cli_tty_cleanup(); /* Restore tty modes etc */
/* This channel hasn't gone yet, so we have > 1 */
@@ -452,7 +452,7 @@ do_escape(unsigned char c) {
}
static
-void cli_escape_handler(struct Channel* UNUSED(channel), unsigned char* buf, int *len) {
+void cli_escape_handler(const struct Channel* UNUSED(channel), const unsigned char* buf, int *len) {
char c;
int skip_char = 0;