Skip to content

Commit

Permalink
Avoid constructing a FilePermission object in checkRead if base manag…
Browse files Browse the repository at this point in the history
…er is null.
  • Loading branch information
jimpurbrick authored and JoshRosen committed Sep 12, 2018
1 parent cd3ff15 commit 01754bf
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,13 @@ public void checkPermission(Permission perm, Object context) {
public static void setExit (PrintStream exit) {
EXIT.set(exit);
}

/**
* Avoid constructing a FilePermission object in checkRead if base manager is null.
*/
public void checkRead(String file) {
if (base != null) {
super.checkRead(file);
}
}
}

0 comments on commit 01754bf

Please sign in to comment.