8289431: (zipfs) Avoid redundant HashMap.get in ZipFileSystemProvider.removeFileSystem
Reviewed-by: lancea, attila
This commit is contained in:
parent
649f2d8835
commit
8e7a3cb5ab
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2009, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2009, 2022, 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
|
||||
@ -308,8 +308,7 @@ public class ZipFileSystemProvider extends FileSystemProvider {
|
||||
} catch (PrivilegedActionException e) {
|
||||
throw (IOException) e.getException();
|
||||
}
|
||||
if (filesystems.get(zfpath) == zfs)
|
||||
filesystems.remove(zfpath);
|
||||
filesystems.remove(zfpath, zfs);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user