Skip to content

Commit ba98d83

Browse files
author
Faisal Hameed
committed
Fixing squid:S1699: Constructors should only call non-overridable methods
1 parent 99e4818 commit ba98d83

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

client/src/main/java/org/asynchttpclient/ntlm/NtlmEngine.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -795,7 +795,7 @@ protected int getPreambleLength() {
795795
}
796796

797797
/** Get the message length */
798-
protected int getMessageLength() {
798+
protected final int getMessageLength() {
799799
return currentOutputPosition;
800800
}
801801

@@ -808,7 +808,7 @@ protected byte readByte(final int position) throws NtlmEngineException {
808808
}
809809

810810
/** Read a bunch of bytes from a position in the message buffer */
811-
protected void readBytes(final byte[] buffer, final int position) throws NtlmEngineException {
811+
protected final void readBytes(final byte[] buffer, final int position) throws NtlmEngineException {
812812
if (messageContents.length < position + buffer.length) {
813813
throw new NtlmEngineException("NTLM: Message too short");
814814
}
@@ -821,12 +821,12 @@ protected int readUShort(final int position) throws NtlmEngineException {
821821
}
822822

823823
/** Read a ulong from a position within the message buffer */
824-
protected int readULong(final int position) throws NtlmEngineException {
824+
protected final int readULong(final int position) throws NtlmEngineException {
825825
return NtlmEngine.readULong(messageContents, position);
826826
}
827827

828828
/** Read a security buffer from a position within the message buffer */
829-
protected byte[] readSecurityBuffer(final int position) throws NtlmEngineException {
829+
protected final byte[] readSecurityBuffer(final int position) throws NtlmEngineException {
830830
return NtlmEngine.readSecurityBuffer(messageContents, position);
831831
}
832832

client/src/main/java/org/asynchttpclient/request/body/multipart/FileLikePart.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public FileLikePart(String name, String contentType, Charset charset, String con
4848
transfertEncoding == null ? DEFAULT_TRANSFER_ENCODING : transfertEncoding);
4949
}
5050

51-
public void setFileName(String fileName) {
51+
public final void setFileName(String fileName) {
5252
this.fileName = fileName;
5353
}
5454

0 commit comments

Comments
 (0)