Mercurial > dropbear
changeset 1538:f20038b513a5
more linting (#58)
* const parameter
* fix indentation
author | François Perrad <francois.perrad@gadz.org> |
---|---|
date | Mon, 26 Feb 2018 14:31:15 +0100 |
parents | 6a83b1944432 |
children | 51df3d53b050 |
files | cli-session.c svr-auth.c svr-runopts.c svr-service.c |
diffstat | 4 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- 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))
--- 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;
--- 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) {
--- 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))