Skip to content

Commit 96dee4c

Browse files
committed
Fix build
1 parent 6cfe664 commit 96dee4c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/jdk/java/net/httpclient/HttpsTunnelAuthTest.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,8 @@ public static void main(String[] args) throws Exception {
176176
try (HttpsTunnelAuthTest test = new HttpsTunnelAuthTest()) {
177177
test.setUp();
178178

179-
try (HttpClient client = test.newHttpClient(test.proxySelector)) {
179+
{
180+
HttpClient client = test.newHttpClient(test.proxySelector);
180181
// tests proxy and server authentication through:
181182
// - plain proxy connection to plain HTTP/1.1 server,
182183
test.test(client, Version.HTTP_1_1, "http", "/foo/http1");
@@ -187,7 +188,8 @@ public static void main(String[] args) throws Exception {
187188
// so that is actually somewhat equivalent to the first case:
188189
// therefore we will use a new client to force re-authentication
189190
// of the proxy connection.
190-
try (HttpClient client = test.newHttpClient(test.proxySelector)) {
191+
{
192+
HttpClient client = test.newHttpClient(test.proxySelector);
191193
test.test(client, Version.HTTP_2, "http", "/foo/http2");
192194

193195
// - proxy tunnel SSL connection to HTTP/1.1 server

0 commit comments

Comments
 (0)