Browse Source

remove unnecessary java.util.Date instantiation

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@278503 13f79535-47bb-0310-9956-ffa450edef68
master
Matthew Jason Benson 20 years ago
parent
commit
f59eb74bbf
1 changed files with 2 additions and 3 deletions
  1. +2
    -3
      src/main/org/apache/tools/ant/util/ResourceUtils.java

+ 2
- 3
src/main/org/apache/tools/ant/util/ResourceUtils.java View File

@@ -79,14 +79,13 @@ public class ResourceUtils {
FileNameMapper mapper,
ResourceFactory targets,
long granularity) {
long now = (new java.util.Date()).getTime() + granularity;
long now = System.currentTimeMillis() + granularity;

Vector vresult = new Vector();
for (int counter = 0; counter < source.length; counter++) {
if (source[counter].getLastModified() > now) {
logTo.log("Warning: " + source[counter].getName()
+ " modified in the future.",
Project.MSG_WARN);
+ " modified in the future.", Project.MSG_WARN);
}
String[] targetnames =
mapper.mapFileName(source[counter].getName()


Loading…
Cancel
Save