Skip to content

Commit

Permalink
Fix typo.
Browse files Browse the repository at this point in the history
  • Loading branch information
cmnbroad committed Sep 21, 2018
1 parent 455b058 commit f408fe7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,7 @@ private ProcessControllerAckResult getNckWithMessageResult() throws IOException
throw new GATKException("Negative ack message length must be > 0");
}

// now get the corresponding message of that length messageLength
final String nckMessage = getIncomingMessage(messageLength);
return new ProcessControllerAckResult(nckMessage);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,13 +200,13 @@ def writeNackWithMessage(self, message: str) -> None:
self.fileWriter.write(toolconstants._nkmString)
actualMessageLength = len(message)
"""The message length must be exactly 4 bytes"""
if len(str(actualMessageLength)) <= toolconstants.nckMessageLengthSerializedSize:
self.fileWriter.write(str(actualMessageLength).zfill(toolconstants.nckMessageLengthSerializedSize))
if len(str(actualMessageLength)) <= toolconstants._nckMessageLengthSerializedSize:
self.fileWriter.write(str(actualMessageLength).zfill(toolconstants._nckMessageLengthSerializedSize))
self.fileWriter.write(message)
else:
"""Message is too long, trim to 9999 bytes"""
self.fileWriter.write(str(toolconstants.nckMaxMessageLength))
self.fileWriter.write(message[:toolconstants.nckMaxMessageLength])
self.fileWriter.write(str(toolconstants._nckMaxMessageLength))
self.fileWriter.write(message[:toolconstants._nckMaxMessageLength])
self.fileWriter.flush()


Expand Down

0 comments on commit f408fe7

Please sign in to comment.