# HG changeset patch # User François Perrad # Date 1519651875 -3600 # Node ID f20038b513a5c0484addd576114e8cd33b6afb59 # Parent 6a83b1944432597106a0046d30966ac30cb53c82 more linting (#58) * const parameter * fix indentation diff -r 6a83b1944432 -r f20038b513a5 cli-session.c --- a/cli-session.c Mon Feb 26 21:17:13 2018 +0800 +++ b/cli-session.c Mon Feb 26 14:31:15 2018 +0100 @@ -181,7 +181,7 @@ } -static void send_msg_service_request(char* servicename) { +static void send_msg_service_request(const char* servicename) { TRACE(("enter send_msg_service_request: servicename='%s'", servicename)) diff -r 6a83b1944432 -r f20038b513a5 svr-auth.c --- a/svr-auth.c Mon Feb 26 21:17:13 2018 +0800 +++ b/svr-auth.c Mon Feb 26 14:31:15 2018 +0100 @@ -38,7 +38,7 @@ #include "dbrandom.h" static void authclear(void); -static int checkusername(char *username, unsigned int userlen); +static int checkusername(const char *username, unsigned int userlen); /* initialise the first time for a session, resetting all parameters */ void svr_authinitialise() { @@ -263,7 +263,7 @@ /* Check that the username exists and isn't disallowed (root), and has a valid shell. * returns DROPBEAR_SUCCESS on valid username, DROPBEAR_FAILURE on failure */ -static int checkusername(char *username, unsigned int userlen) { +static int checkusername(const char *username, unsigned int userlen) { char* listshell = NULL; char* usershell = NULL; diff -r 6a83b1944432 -r f20038b513a5 svr-runopts.c --- a/svr-runopts.c Mon Feb 26 21:17:13 2018 +0800 +++ b/svr-runopts.c Mon Feb 26 14:31:15 2018 +0100 @@ -542,7 +542,7 @@ #if DROPBEAR_ECDSA loadhostkey(ECDSA_PRIV_FILENAME, 0); #endif - } + } #if DROPBEAR_DELAY_HOSTKEY if (svr_opts.delay_hostkey) { diff -r 6a83b1944432 -r f20038b513a5 svr-service.c --- a/svr-service.c Mon Feb 26 21:17:13 2018 +0800 +++ b/svr-service.c Mon Feb 26 14:31:15 2018 +0100 @@ -30,7 +30,7 @@ #include "ssh.h" #include "auth.h" -static void send_msg_service_accept(char *name, int len); +static void send_msg_service_accept(const char *name, int len); /* processes a SSH_MSG_SERVICE_REQUEST, returning 0 if finished, * 1 if not */ @@ -73,7 +73,7 @@ } -static void send_msg_service_accept(char *name, int len) { +static void send_msg_service_accept(const char *name, int len) { TRACE(("accepting service %s", name))