You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2018/07/30 21:44:40 UTC

[2/5] httpcomponents-core git commit: Make private ivar final.

Make private ivar final.


Project: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/commit/730cbbb5
Tree: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/tree/730cbbb5
Diff: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/diff/730cbbb5

Branch: refs/heads/master
Commit: 730cbbb5f6e6ea6d99f0f8217cee236bccf3d2ec
Parents: 060ab89
Author: Gary Gregory <gg...@apache.org>
Authored: Mon Jul 30 12:28:04 2018 -0600
Committer: Oleg Kalnichevski <ol...@apache.org>
Committed: Mon Jul 30 23:42:05 2018 +0200

----------------------------------------------------------------------
 .../org/apache/hc/core5/http/nio/entity/FileEntityProducer.java    | 2 +-
 .../java/org/apache/hc/core5/http/impl/io/TestHttpService.java     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/httpcomponents-core/blob/730cbbb5/httpcore5/src/main/java/org/apache/hc/core5/http/nio/entity/FileEntityProducer.java
----------------------------------------------------------------------
diff --git a/httpcore5/src/main/java/org/apache/hc/core5/http/nio/entity/FileEntityProducer.java b/httpcore5/src/main/java/org/apache/hc/core5/http/nio/entity/FileEntityProducer.java
index 6b26d9c..bd7b18f 100644
--- a/httpcore5/src/main/java/org/apache/hc/core5/http/nio/entity/FileEntityProducer.java
+++ b/httpcore5/src/main/java/org/apache/hc/core5/http/nio/entity/FileEntityProducer.java
@@ -50,7 +50,7 @@ public final class FileEntityProducer implements AsyncEntityProducer {
     private final ContentType contentType;
     private final AtomicReference<Exception> exception;
 
-    private AtomicReference<RandomAccessFile> accessFileRef;
+    private final AtomicReference<RandomAccessFile> accessFileRef;
     private boolean eof;
 
     public FileEntityProducer(final File file, final int bufferSize, final ContentType contentType) {

http://git-wip-us.apache.org/repos/asf/httpcomponents-core/blob/730cbbb5/httpcore5/src/test/java/org/apache/hc/core5/http/impl/io/TestHttpService.java
----------------------------------------------------------------------
diff --git a/httpcore5/src/test/java/org/apache/hc/core5/http/impl/io/TestHttpService.java b/httpcore5/src/test/java/org/apache/hc/core5/http/impl/io/TestHttpService.java
index 656c677..7dd9717 100644
--- a/httpcore5/src/test/java/org/apache/hc/core5/http/impl/io/TestHttpService.java
+++ b/httpcore5/src/test/java/org/apache/hc/core5/http/impl/io/TestHttpService.java
@@ -69,7 +69,7 @@ public class TestHttpService {
     @Mock
     private ConnectionReuseStrategy connReuseStrategy;
     @Spy
-    private ClassicHttpResponse response = new BasicClassicHttpResponse(HttpStatus.SC_OK);
+    private final ClassicHttpResponse response = new BasicClassicHttpResponse(HttpStatus.SC_OK);
     @Mock
     private HttpResponseFactory<ClassicHttpResponse> responseFactory;
     @Mock