@@ -2305,17 +2305,17 @@ nc_server_config_delete_substring(const char *haystack, const char *needle, cons
23052305static int
23062306nc_server_config_transport_params (const char * algorithm , char * * alg_store , enum nc_operation op )
23072307{
2308- int ret = 0 ;
2308+ int ret = 0 , r ;
23092309 char * alg = NULL ;
23102310
23112311 if (!strncmp (algorithm , "openssh-" , 8 )) {
23122312 /* if the name starts with openssh, convert it to it's original libssh accepted form */
2313- ret = asprintf (
& alg ,
"%[email protected] " ,
algorithm + 8 );
2314- NC_CHECK_ERRMEM_GOTO (ret == -1 , ret = 1 ; alg = NULL , cleanup );
2313+ r = asprintf (
& alg ,
"%[email protected] " ,
algorithm + 8 );
2314+ NC_CHECK_ERRMEM_GOTO (r == -1 , ret = 1 ; alg = NULL , cleanup );
23152315 } else if (!strncmp (algorithm , "libssh-" , 7 )) {
23162316 /* if the name starts with libssh, convert it to it's original libssh accepted form */
2317- ret = asprintf (
& alg ,
"%[email protected] " ,
algorithm + 7 );
2318- NC_CHECK_ERRMEM_GOTO (ret == -1 , ret = 1 ; alg = NULL , cleanup );
2317+ r = asprintf (
& alg ,
"%[email protected] " ,
algorithm + 7 );
2318+ NC_CHECK_ERRMEM_GOTO (r == -1 , ret = 1 ; alg = NULL , cleanup );
23192319 } else {
23202320 alg = strdup (algorithm );
23212321 NC_CHECK_ERRMEM_GOTO (!alg , ret = 1 , cleanup );
0 commit comments