[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Warning reported by gcc-4.4.1
[Thread Prev] | [Thread Next]
- Subject: Warning reported by gcc-4.4.1
- From: "Dmitry V. Krivenok" <krivenok@xxxxxxxxxxxxxxx>
- Reply-to: krivenok@xxxxxxxxxxxxxxx
- Reply-to: libssh@xxxxxxxxxx
- Date: Thu, 10 Sep 2009 14:06:23 +0400
- To: libssh@xxxxxxxxxx
Hello! gcc-4.4.1 reports one warning during compilation of libssh. Attached patch fixes the problem. -- Sincerely yours, Dmitry V. Krivenok Orange System Co., Ltd. Saint-Petersburg, Russia work phone: +7 812 332-32-40 cellular phone: +7 921 576-70-91 e-mail: krivenok@xxxxxxxxxxxxxxx web: http://www.orangesystem.ru skype: krivenok_dmitry jabber: krivenok_dmitry@xxxxxxxxx icq: 242-526-443
From 4287a29d886725ed3b876d1af0c867e207a76dab Mon Sep 17 00:00:00 2001 From: Dmitry V. Krivenok <krivenok@xxxxxxxxxxxxxxx> Date: Thu, 10 Sep 2009 13:57:05 +0400 Subject: [PATCH] Fixed "var is uninitialized" bug. gcc-4.4.1 reported: /home/krivenok/dev_builds/libssh/libssh/sftp.c:2700: warning: 'sftp' is used uninitialized in this function sftp is NULL-initialized now. Signed-off-by: Dmitry V. Krivenok <krivenok@xxxxxxxxxxxxxxx> --- libssh/sftp.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/libssh/sftp.c b/libssh/sftp.c index 40510ed..9467f95 100644 --- a/libssh/sftp.c +++ b/libssh/sftp.c @@ -2692,7 +2692,7 @@ SFTP_STATVFS *sftp_statvfs(SFTP_SESSION *sftp, const char *path) { SFTP_STATVFS *sftp_fstatvfs(SFTP_FILE *file) { STATUS_MESSAGE *status = NULL; SFTP_MESSAGE *msg = NULL; - SFTP_SESSION *sftp; + SFTP_SESSION *sftp = NULL; ssh_string ext; ssh_buffer buffer; uint32_t id; -- 1.6.3.3
Archive administrator: postmaster@lists.cynapses.org