Browse Source

Declare BuildException in Sleep.validate explicitly.

Submitted by:	Steve Loughran <steve_l@iseran.com>


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@269226 13f79535-47bb-0310-9956-ffa450edef68
master
Stefan Bodewig 24 years ago
parent
commit
ea556429da
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      src/main/org/apache/tools/ant/taskdefs/Sleep.java

+ 2
- 1
src/main/org/apache/tools/ant/taskdefs/Sleep.java View File

@@ -177,7 +177,8 @@ public class Sleep extends Task {
* *
* @throws BuildException if something is invalid * @throws BuildException if something is invalid
*/ */
public void validate() {
public void validate()
throws BuildException {
long sleepTime = getSleepTime(); long sleepTime = getSleepTime();
if (getSleepTime() < 0) { if (getSleepTime() < 0) {
throw new BuildException("Negative sleep periods are not supported"); throw new BuildException("Negative sleep periods are not supported");


Loading…
Cancel
Save