8251329: (zipfs) Files.walkFileTree walks infinitely if zip has dir named "." inside

Reviewed-by: alanb, naoto
This commit is contained in:
Lance Andersen 2021-08-02 15:47:16 +00:00
parent 7a4c754e5d
commit 3e3051e2ee
3 changed files with 201 additions and 1 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -45,6 +45,9 @@ import java.util.Set;
* <li>Open an existing file as a Zip file system</li>
* </ul>
*
* The Zip file system provider does not support opening an existing Zip file
* that contains entries with "." or ".." in its name elements.
*
* <h2>URI Scheme Used to Identify the Zip File System</h2>
*
* The URI {@link java.net.URI#getScheme scheme} that identifies the ZIP file system is {@code jar}.