diff options
author | Oleg Besedin | 2010-01-25 21:22:34 +0000 |
---|---|---|
committer | Oleg Besedin | 2010-01-25 21:22:34 +0000 |
commit | 60b3630500f10828f0537ab04521187952034ba6 (patch) | |
tree | f8e5ab74a188faf20912de3577f97066bf1f0304 /bundles/org.eclipse.equinox.security | |
parent | ba4699d9f9c00d7174574769cfe7a15dbbe160eb (diff) | |
download | rt.equinox.bundles-60b3630500f10828f0537ab04521187952034ba6.tar.gz rt.equinox.bundles-60b3630500f10828f0537ab04521187952034ba6.tar.xz rt.equinox.bundles-60b3630500f10828f0537ab04521187952034ba6.zip |
Diffstat (limited to 'bundles/org.eclipse.equinox.security')
3 files changed, 8 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/SecAuthMessages.java b/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/SecAuthMessages.java index d978f1af4..7e3e397f3 100644 --- a/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/SecAuthMessages.java +++ b/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/SecAuthMessages.java @@ -29,6 +29,7 @@ public class SecAuthMessages extends NLS { public static String startFirst; public static String stopFirst; public static String unsupoprtedCharEncoding; + public static String badStorageURL; // Configuration provider public static String unexpectedConfigElement; diff --git a/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/messages.properties b/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/messages.properties index f87774348..b4603e1d4 100644 --- a/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/messages.properties +++ b/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/auth/nls/messages.properties @@ -22,6 +22,7 @@ loginFailure = Failed to log in. startFirst = Secure platform is not running. Make sure that secure platform is started. stopFirst = Secure platform is already running. Make sure that secure platform is stopped first. unsupoprtedCharEncoding = Default secure storage encoding \"{0}\" is not supported by the Java virtual machine. +badStorageURL = Unable to resolve secure storage location \"{0}\". ## Configuration provider invalidConfigURL = Invalid URL \"{0}\" specified by \"{1}\" for Configuration provider. diff --git a/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/storage/SecurePreferencesRoot.java b/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/storage/SecurePreferencesRoot.java index f372ccf37..aa777a85c 100644 --- a/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/storage/SecurePreferencesRoot.java +++ b/bundles/org.eclipse.equinox.security/src/org/eclipse/equinox/internal/security/storage/SecurePreferencesRoot.java @@ -68,7 +68,7 @@ public class SecurePreferencesRoot extends SecurePreferences implements IStorage static private ILock lock = Job.getJobManager().newLock(); - final private URL location; + private URL location; private long timestamp = 0; @@ -112,6 +112,11 @@ public class SecurePreferencesRoot extends SecurePreferences implements IStorage properties.load(is); timestamp = getLastModified(); } + } catch (IllegalArgumentException e) { + String msg = NLS.bind(SecAuthMessages.badStorageURL, location.toString()); + AuthPlugin.getDefault().logError(msg, e); + location = null; // don't attempt to use it + return; } finally { if (is != null) is.close(); |