提交 487d0db9 authored 作者: Thomas Mueller's avatar Thomas Mueller

When running H2 in the Google AppEngine for Java, a AccessControlException could be thrown.

上级 43bce1b4
......@@ -286,9 +286,15 @@ public class FileSystemDisk extends FileSystem {
}
private boolean canWriteInternal(File file) {
try {
if (!file.canWrite()) {
return false;
}
} catch (Exception e) {
// workaround for GAE which throws a
// java.security.AccessControlException
return false;
}
// File.canWrite() does not respect windows user permissions,
// so we must try to open it using the mode "rw".
// See also http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4420020
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论