Don't auto-send STOMP content-length header if one was explicitly set

This commit is contained in:
Ville Skyttä 2015-07-20 12:01:46 +03:00 committed by Clebert Suconic
parent 96b559307c
commit 642838c712
1 changed files with 1 additions and 1 deletions

View File

@ -66,7 +66,7 @@ public class StompFrameV11 extends StompFrame
head.append(h.getEncodedValue());
head.append(Stomp.NEWLINE);
}
if (bytesBody != null && bytesBody.length > 0)
if (bytesBody != null && bytesBody.length > 0 && !hasHeader(Stomp.Headers.CONTENT_LENGTH))
{
head.append(Stomp.Headers.CONTENT_LENGTH);
head.append(Stomp.Headers.SEPARATOR);