Skip to content

Commit

Permalink
Append the auth reply to the right buffer
Browse files Browse the repository at this point in the history
  • Loading branch information
npmccallum committed Feb 2, 2018
1 parent a49840b commit 466c522
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,11 @@ public APDUReply handle(APDURequest req) throws PacketableException {

// Create the reply message.
ByteBuffer out = ByteBuffer.allocate(5 + sig.length);
pay.put(up);
pay.putInt(0);
pay.put(sig);
out.put(up);
out.putInt(0);
out.put(sig);

return new APDUReply(APDUReply.StatusCode.NO_ERROR, pay.array());
return new APDUReply(APDUReply.StatusCode.NO_ERROR, out.array());
} catch (Exception e) {
e.printStackTrace();
throw new PacketableException(APDUReply.StatusCode.WRONG_DATA);
Expand Down

0 comments on commit 466c522

Please sign in to comment.