mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-07-31 00:03:07 +03:00
Fix a bunch of -Wmaybe-uninitialized
Reviewed-By: Aris Adamantiadis <aris@0xbadc0de.be>
This commit is contained in:
committed by
Aris Adamantiadis
parent
71ce6592e4
commit
0d7da3207f
@ -181,7 +181,7 @@ void ssh_mac_update(ssh_mac_ctx ctx, const void *data, unsigned long len) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void ssh_mac_final(unsigned char *md, ssh_mac_ctx ctx) {
|
void ssh_mac_final(unsigned char *md, ssh_mac_ctx ctx) {
|
||||||
size_t len;
|
size_t len = 0;
|
||||||
switch(ctx->mac_type){
|
switch(ctx->mac_type){
|
||||||
case SSH_MAC_SHA1:
|
case SSH_MAC_SHA1:
|
||||||
len=SHA_DIGEST_LEN;
|
len=SHA_DIGEST_LEN;
|
||||||
|
@ -1753,7 +1753,7 @@ ssh_string ssh_srv_pki_do_sign_sessionid(ssh_session session,
|
|||||||
const ssh_key privkey)
|
const ssh_key privkey)
|
||||||
{
|
{
|
||||||
struct ssh_crypto_struct *crypto;
|
struct ssh_crypto_struct *crypto;
|
||||||
ssh_signature sig;
|
ssh_signature sig = NULL;
|
||||||
ssh_string sig_blob;
|
ssh_string sig_blob;
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
|
@ -737,7 +737,7 @@ int pki_pubkey_build_ecdsa(ssh_key key, int nid, ssh_string e)
|
|||||||
ssh_key pki_key_dup(const ssh_key key, int demote)
|
ssh_key pki_key_dup(const ssh_key key, int demote)
|
||||||
{
|
{
|
||||||
ssh_key new;
|
ssh_key new;
|
||||||
gcry_sexp_t sexp;
|
gcry_sexp_t sexp = NULL;
|
||||||
gcry_error_t err;
|
gcry_error_t err;
|
||||||
const char *tmp = NULL;
|
const char *tmp = NULL;
|
||||||
size_t size;
|
size_t size;
|
||||||
|
@ -45,7 +45,7 @@ int benchmarks_sync_sftp_up (ssh_session session, struct argument_s *args,
|
|||||||
float ms=0.0;
|
float ms=0.0;
|
||||||
unsigned long total=0;
|
unsigned long total=0;
|
||||||
sftp_session sftp;
|
sftp_session sftp;
|
||||||
sftp_file file;
|
sftp_file file = NULL;
|
||||||
|
|
||||||
bytes = args->datasize * 1024 * 1024;
|
bytes = args->datasize * 1024 * 1024;
|
||||||
sftp = sftp_new(session);
|
sftp = sftp_new(session);
|
||||||
@ -101,7 +101,7 @@ int benchmarks_sync_sftp_down (ssh_session session, struct argument_s *args,
|
|||||||
float ms=0.0;
|
float ms=0.0;
|
||||||
unsigned long total=0;
|
unsigned long total=0;
|
||||||
sftp_session sftp;
|
sftp_session sftp;
|
||||||
sftp_file file;
|
sftp_file file = NULL;
|
||||||
int r;
|
int r;
|
||||||
|
|
||||||
bytes = args->datasize * 1024 * 1024;
|
bytes = args->datasize * 1024 * 1024;
|
||||||
@ -163,7 +163,7 @@ int benchmarks_async_sftp_down (ssh_session session, struct argument_s *args,
|
|||||||
float ms=0.0;
|
float ms=0.0;
|
||||||
unsigned long total=0;
|
unsigned long total=0;
|
||||||
sftp_session sftp;
|
sftp_session sftp;
|
||||||
sftp_file file;
|
sftp_file file = NULL;
|
||||||
int r,i;
|
int r,i;
|
||||||
int warned = 0;
|
int warned = 0;
|
||||||
unsigned long toread;
|
unsigned long toread;
|
||||||
|
Reference in New Issue
Block a user