Browse Source

Misc. corrections in SignJar.java

PR: 28999
Obtained from: Jesse Glick


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@276454 13f79535-47bb-0310-9956-ffa450edef68
master
Peter Reilly 21 years ago
parent
commit
52a4c5f901
1 changed files with 3 additions and 6 deletions
  1. +3
    -6
      src/main/org/apache/tools/ant/taskdefs/SignJar.java

+ 3
- 6
src/main/org/apache/tools/ant/taskdefs/SignJar.java View File

@@ -31,14 +31,11 @@ import org.apache.tools.ant.util.JavaEnvUtils;
import org.apache.tools.ant.util.FileUtils; import org.apache.tools.ant.util.FileUtils;


/** /**
* Signs jar or zip files with the javasign command line tool. The
* Signs JAR or ZIP files with the javasign command line tool. The
* tool detailed dependency checking: files are only signed if they * tool detailed dependency checking: files are only signed if they
* are not signed. The <tt>signjar</tt> attribute can point to the file to * are not signed. The <tt>signjar</tt> attribute can point to the file to
* generate; if this file exists then * generate; if this file exists then
* its modification date is used as a cue as to whether to resign any JAR file. * its modification date is used as a cue as to whether to resign any JAR file.
* <br>
* <strong>Note:</strong> Requires Java 1.2 or later. </p>

* *
* @since Ant 1.1 * @since Ant 1.1
* @ant.task category="java" * @ant.task category="java"
@@ -300,7 +297,7 @@ public class SignJar extends Task {


cmd.createArg().setValue(alias); cmd.createArg().setValue(alias);


log("Signing Jar : " + jarSource.getAbsolutePath());
log("Signing JAR: " + jarSource.getAbsolutePath());
cmd.setFailonerror(true); cmd.setFailonerror(true);
cmd.setTaskName(getTaskName()); cmd.setTaskName(getTaskName());
cmd.execute(); cmd.execute();
@@ -338,7 +335,7 @@ public class SignJar extends Task {
* test for a file being signed, by looking for a signature in the META-INF * test for a file being signed, by looking for a signature in the META-INF
* directory * directory
* @param file * @param file
* @return
* @return true if the file is signed
*/ */
protected boolean isSigned(File file) { protected boolean isSigned(File file) {
final String SIG_START = "META-INF/"; final String SIG_START = "META-INF/";


Loading…
Cancel
Save