Author: kevj Date: Sun May 28 19:55:43 2006 New Revision: 410014 URL: http://svn.apache.org/viewvc?rev=410014&view=rev Log: remove deprecated code
Modified: ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/BuildNumber.java Modified: ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/BuildNumber.java URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/BuildNumber.java?rev=410014&r1=410013&r2=410014&view=diff ============================================================================== --- ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/BuildNumber.java (original) +++ ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/BuildNumber.java Sun May 28 19:55:43 2006 @@ -1,5 +1,5 @@ /* - * Copyright 2002-2005 The Apache Software Foundation + * Copyright 2002-2006 The Apache Software Foundation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -129,7 +129,6 @@ } catch (final NumberFormatException nfe) { final String message = myFile + " contains a non integer build number: " + buildNumber; - throw new BuildException(message, nfe); } } @@ -173,7 +172,7 @@ private void validate() throws BuildException { if (null == myFile) { - myFile = getProject().resolveFile(DEFAULT_FILENAME); + myFile = FILE_UTILS.resolveFile(getProject().getBaseDir(), DEFAULT_FILENAME); } if (!myFile.exists()) { @@ -182,20 +181,17 @@ } catch (final IOException ioe) { final String message = myFile + " doesn't exist and new file can't be created."; - throw new BuildException(message, ioe); } } if (!myFile.canRead()) { final String message = "Unable to read from " + myFile + "."; - throw new BuildException(message); } if (!myFile.canWrite()) { final String message = "Unable to write to " + myFile + "."; - throw new BuildException(message); } } --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]