Skip to content

Commit 1336da1

Browse files
authored
Merge pull request arduino#472 from tekka007/SigningFix
Fix sending buffer in MySigning.cpp
2 parents 10ebe9c + c1c37b0 commit 1336da1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: libraries/MySensors/core/MySigning.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ static void prepareSigningPresentation(MyMessage &msg, uint8_t destination) {
106106
// Only supports version 1 for now
107107
build(msg, _nc.nodeId, destination, NODE_SENSOR_ID, C_INTERNAL, I_SIGNING_PRESENTATION, false).set("");
108108
mSetLength(msg, 2);
109+
mSetPayloadType(msg, P_CUSTOM); // displayed as hex
109110
msg.data[0] = SIGNING_PRESENTATION_VERSION_1;
110111
msg.data[1] = 0;
111112
}
@@ -303,7 +304,7 @@ bool signerSignMsg(MyMessage &msg) {
303304
} else {
304305
// Send nonce-request
305306
_signingNonceStatus=SIGN_WAITING_FOR_NONCE;
306-
if (!_sendRoute(build(_msgTmp, _nc.nodeId, msg.destination, msg.sensor,
307+
if (!_sendRoute(build(_msgSign, _nc.nodeId, msg.destination, msg.sensor,
307308
C_INTERNAL, I_NONCE_REQUEST, false).set(""))) {
308309
SIGN_DEBUG(PSTR("Failed to transmit nonce request!\n"));
309310
return false;

0 commit comments

Comments
 (0)