examples: Reformat connect_ssh.c

Signed-off-by: Jakub Jelen <jjelen@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Jakub Jelen
2025-04-24 14:47:23 +02:00
committed by Andreas Schneider
parent d38007c4be
commit 986e0c593f

View File

@@ -21,7 +21,8 @@ clients must be made or how a client should react.
#include "examples_common.h"
#include <stdio.h>
ssh_session connect_ssh(const char *host, const char *user,int verbosity){
ssh_session connect_ssh(const char *host, const char *user, int verbosity)
{
ssh_session session;
int auth = 0;
@@ -59,7 +60,9 @@ ssh_session connect_ssh(const char *host, const char *user,int verbosity){
} else if (auth == SSH_AUTH_DENIED) {
fprintf(stderr, "Authentication failed\n");
} else {
fprintf(stderr,"Error while authenticating : %s\n",ssh_get_error(session));
fprintf(stderr,
"Error while authenticating : %s\n",
ssh_get_error(session));
}
ssh_disconnect(session);
ssh_free(session);