Author: jleroux
Date: Tue Feb 10 10:47:01 2009
New Revision: 742933
URL:
http://svn.apache.org/viewvc?rev=742933&view=revLog:
A patch from Marco Ruocco "Error using the UtilDateTime.addDaysToTimestamp method" (
https://issues.apache.org/jira/browse/OFBIZ-2177) - OFBIZ-2177
Modified:
ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java
Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java?rev=742933&r1=742932&r2=742933&view=diff==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java Tue Feb 10 10:47:01 2009
@@ -79,11 +79,11 @@
}
public static Timestamp addDaysToTimestamp(Timestamp start, int days) {
- return new Timestamp(start.getTime() + (24*60*60*1000*days));
+ return new Timestamp(start.getTime() + (24L*60L*60L*1000L*days));
}
public static Timestamp addDaysToTimestamp(Timestamp start, Double days) {
- return new Timestamp(start.getTime() + ((int) (24*60*60*1000*days)));
+ return new Timestamp(start.getTime() + ((int) (24L*60L*60L*1000L*days)));
}
public static double getInterval(Timestamp from, Timestamp thru) {