Subject: [libssh2] [PATCH] sftp: remove wrong cast

[libssh2] [PATCH] sftp: remove wrong cast

From: Sebastian Siewior <libssh2-devel_at_ml.breakpoint.cc>
Date: Mon, 23 Jun 2008 23:58:11 +0200

|sftp.c:1470: warning: cast to pointer from integer of different size
Another reason why macros are evil: The string (which is allready char *) should
be cast into char * not the integer.

Signed-off-by: Sebastian Siewior <sebastian_at_breakpoint.cc>

---
 src/sftp.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/sftp.c b/src/sftp.c
index 8cbd382..51a3d41 100644
--- a/src/sftp.c
+++ b/src/sftp.c
@@ -1468,8 +1468,8 @@ libssh2_sftp_fstat_ex(LIBSSH2_SFTP_HANDLE * handle,
             return PACKET_EAGAIN;
         } else if (packet_len != rc) {
             libssh2_error(session, LIBSSH2_ERROR_SOCKET_SEND,
-                          setstat ? (char *) "Unable to send FXP_FSETSTAT"
-                          : (char *) "Unable to send FXP_FSTAT command", 0);
+                          (setstat ? "Unable to send FXP_FSETSTAT"
+                          : "Unable to send FXP_FSTAT command"), 0);
             LIBSSH2_FREE(session, sftp->fstat_packet);
             sftp->fstat_packet = NULL;
             sftp->fstat_state = libssh2_NB_state_idle;
-- 
1.5.5.1
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
libssh2-devel mailing list
libssh2-devel_at_lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libssh2-devel
Received on 2008-06-23