[Swift-commit] cog r3808
swift at ci.uchicago.edu
swift at ci.uchicago.edu
Fri Oct 11 21:25:04 CDT 2013
------------------------------------------------------------------------
r3808 | hategan | 2013-10-11 21:21:14 -0500 (Fri, 11 Oct 2013) | 1 line
ensure that CA directory exists (when only the file lock was used it would create this directory, but after that was abandoned this stopped being the case). If the listing of files in the CA dir fails, throw an exception with a clear message instead of a NPE (see bug #1109)(merge from branches/4.1.10)
------------------------------------------------------------------------
Index: modules/provider-coaster/src/org/globus/cog/abstraction/impl/execution/coaster/AutoCA.java
===================================================================
--- modules/provider-coaster/src/org/globus/cog/abstraction/impl/execution/coaster/AutoCA.java (revision 3807)
+++ modules/provider-coaster/src/org/globus/cog/abstraction/impl/execution/coaster/AutoCA.java (working copy)
@@ -136,6 +136,9 @@
try {
File[] certs = discoverProxies();
+ if (certs == null) {
+ throw new IOException("Failed to list files in CA directory (" + CA_DIR + ")");
+ }
long now = System.currentTimeMillis();
long maxExpirationTime = 0;
@@ -217,6 +220,8 @@
}
private Object lockDir(String caDir) {
+ File caDirFile = new File(caDir);
+ caDirFile.mkdirs();
if (SHARED_PROXIES) {
FileLock fl = new FileLock(CA_DIR);
try {
More information about the Swift-commit
mailing list