#include "utils/Log.h"
+#include <stdint.h>
#include <string.h>
#include <assert.h>
* and capability flags.
*/
if (initiateHello) {
- long data = kHelloMsg;
+ int32_t data = kHelloMsg;
Message msg;
/* send hello */
return false;
}
- const long* pAck;
- pAck = (const long*) msg.getData();
+ const int32_t* pAck;
+ pAck = (const int32_t*) msg.getData();
if (pAck == NULL || *pAck != kHelloAckMsg) {
- LOG(LOG_WARN, "", "hello ack was bad\n");
+ LOG(LOG_WARN, "", "hello ack was bad (%08x vs %08x)\n",
+ *pAck, kHelloAckMsg);
return false;
}
} else {
- long data = kHelloAckMsg;
+ int32_t data = kHelloAckMsg;
Message msg;
LOG(LOG_DEBUG, "", "waiting for hello from peer\n");
return false;
}
- const long* pAck;
- pAck = (const long*) msg.getData();
+ const int32_t* pAck;
+ pAck = (const int32_t*) msg.getData();
if (pAck == NULL || *pAck != kHelloMsg) {
LOG(LOG_WARN, "", "hello was bad\n");
return false;
goto bail;
}
} else if (msg.mType == kTypeConfig) {
- const char *name;
- const char *val;
+ const char* name = NULL;
+ const char* val = NULL;
getConfig(&msg, &name, &val);
if(strcmp(name, "keycharmap") == 0) {
free((void*)gWrapSim.keyMap);