cURL / Mailing Lists / curl-library / Single Mail

curl-library

Bug in ssh.c?

From: Daniel Johnson <daniel.johnson31_at_gmail.com>
Date: Wed, 2 Sep 2009 15:15:42 -0400

I was experimenting with building libcurl with clang and it found
something:

../../curl/lib/ssh.c:239:10: warning: overflow converting case value
to switch condition type (-6 to 4294967290)
     case LIBSSH2_ERROR_ALLOC:
          ^
/Volumes/MacintoshHD/deps/include/libssh2.h:326:49: note: instantiated
from:
#define LIBSSH2_ERROR_ALLOC -6
                                                 ^
1 diagnostic generated.

Sure enough, err is declared to be unsigned long. Perhaps
sftp_libssh2_error_to_CURLE should take a signed long instead?

Daniel

  • application/pkcs7-signature attachment: smime.p7s
Received on 2009-09-02