Clean up build warnings under Linux

pull/1/head
John Safranek 2014-08-14 11:46:23 -07:00
parent c142bc305c
commit 917c6a84c4
3 changed files with 7 additions and 5 deletions

View File

@ -34,6 +34,9 @@
#include <stdio.h>
#include <pthread.h>
#include <wolfssh/ssh.h>
#ifndef SO_NOSIGPIPE
#include <signal.h>
#endif
typedef int SOCKET_T;

View File

@ -527,8 +527,9 @@ static int DoNameList(uint8_t* idList, uint32_t* idListSz,
id = NameToId((char*)name, nameSz);
{
const char* displayName = IdToName(id);
if (displayName)
if (displayName) {
WLOG(WS_LOG_DEBUG, "DNL: name ID = %s", displayName);
}
}
if (id != ID_UNKNOWN)
idList[idListIdx++] = id;
@ -1295,6 +1296,8 @@ int SendKexDhReply(WOLFSSH* ssh)
/* Hash in the server's RSA key. */
InitRsaKey(&rsaKey, ssh->ctx->heap);
ret = RsaPrivateKeyDecode(ssh->ctx->privateKey, &scratch, &rsaKey, (int)ssh->ctx->privateKeySz);
if (ret < 0)
return ret;
RsaFlattenPublicKey(&rsaKey, rsaE, &rsaESz, rsaN, &rsaNSz);
if (rsaE[0] & 0x80) rsaEPad = 1;
if (rsaN[0] & 0x80) rsaNPad = 1;

View File

@ -262,10 +262,6 @@ enum WS_MessageIds {
};
WOLFSSH_LOCAL int ProcessClientVersion(WOLFSSH*);
WOLFSSH_LOCAL int SendServerVersion(WOLFSSH*);
/* dynamic memory types */
enum WS_DynamicTypes {
DYNTYPE_CTX,