hello all,

the attached patch --already committed-- (which should be part of the fix for 
PR 28391) ensures that the default keystore (.keystore in user's home) is not 
created unless required.


2006-07-17  Raif S. Naffah  <[EMAIL PROTECTED]>

        * tools/gnu/classpath/tools/keytool/Command.java (setKeystoreURLParam):
        Condition the creation of .keystore (a default keystore) based on the
        createIfNotFound argument as well.


cheers;
rsn
Index: tools/gnu/classpath/tools/keytool/Command.java
===================================================================
RCS file: /cvsroot/classpath/classpath/tools/gnu/classpath/tools/keytool/Command.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -U3 -r1.7 -r1.8
--- tools/gnu/classpath/tools/keytool/Command.java	16 Jul 2006 05:55:59 -0000	1.7
+++ tools/gnu/classpath/tools/keytool/Command.java	16 Jul 2006 16:35:44 -0000	1.8
@@ -573,8 +573,9 @@
           throw new InvalidParameterException(Messages.getString("Command.36")); //$NON-NLS-1$
 
         url = userHome.trim() + "/.keystore"; //$NON-NLS-1$
-        // if it does not exist create it
-        new File(url).createNewFile();
+        // if it does not exist create it if required
+        if (createIfNotFound)
+          new File(url).createNewFile();
         url = "file:" + url; //$NON-NLS-1$
       }
     else

Reply via email to