unrelated: got rid of some warnings

This commit is contained in:
notsecure 2014-06-23 15:17:28 -04:00
parent 3303b29da1
commit 97c548bc80
2 changed files with 5 additions and 10 deletions

View File

@ -116,7 +116,7 @@ typedef struct _MSIMessage {
static struct _Callbacks {
MSICallback function;
void *data;
} callbacks[11] = {0};
} callbacks[11] = {{0}};
inline__ void invoke_callback(int32_t call_index, MSICallbackID id)
{
@ -736,13 +736,7 @@ int send_message ( MSISession *session, MSICall *call, MSIMessage *msg, uint32_t
*/
int call_id_bigger( const uint8_t *first, const uint8_t *second)
{
int i = 0;
for (; i < CALL_ID_LEN; i ++) {
if ( first[i] != second[i] )
return first[i] > second [i] ? 0 : 1;
}
return (memcmp(first, second, CALL_ID_LEN) < 0);
}

View File

@ -26,6 +26,7 @@
#endif
#include "../toxcore/Messenger.h"
#include "../toxcore/logger.h"
#include "toxdns.h"
static const char base32[32] = {"abcdefghijklmnopqrstuvwxyz012345"};
@ -43,7 +44,7 @@ uint8_t i = 0; \
} \
} \
} \
typedef struct {
uint8_t temp_pk[crypto_box_PUBLICKEYBYTES];
uint8_t temp_sk[crypto_box_SECRETKEYBYTES];
@ -143,7 +144,7 @@ int tox_generate_dns3_string(void *dns3_object, uint8_t *string, uint16_t string
}
if (end_len != string - old_str) {
printf("tox_generate_dns3_string Fail, %u != %u\n", end_len, string - old_str);
LOGGER_ERROR("tox_generate_dns3_string Fail, %u != %lu\n", end_len, string - old_str);
return -1;
}