summaryrefslogtreecommitdiffstats
path: root/libjava/java
diff options
context:
space:
mode:
authormkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4>2005-04-20 06:01:09 +0000
committermkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4>2005-04-20 06:01:09 +0000
commitb1fef53a94dcbf468b2280fe532ca431c9b2c72e (patch)
treeeb65c78a8663de4b97d122a340d04d43757d8d6b /libjava/java
parent48ad7977452a698de4807c65502abe69d8f1da90 (diff)
downloadppe42-gcc-b1fef53a94dcbf468b2280fe532ca431c9b2c72e.tar.gz
ppe42-gcc-b1fef53a94dcbf468b2280fe532ca431c9b2c72e.zip
2005-04-20 Sven de Marothy <sven@physto.se>
* java/text/SimpleDateFormat.java: (formatWithAttribute): Pad year before truncating digits. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@98444 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/java')
-rw-r--r--libjava/java/text/SimpleDateFormat.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/libjava/java/text/SimpleDateFormat.java b/libjava/java/text/SimpleDateFormat.java
index 190b4d624f4..06275b628ca 100644
--- a/libjava/java/text/SimpleDateFormat.java
+++ b/libjava/java/text/SimpleDateFormat.java
@@ -680,7 +680,7 @@ public class SimpleDateFormat extends DateFormat
buffer.setDefaultAttribute (DateFormat.Field.YEAR);
if (cf.getSize() == 2)
{
- temp = String.valueOf (calendar.get (Calendar.YEAR));
+ temp = "00"+String.valueOf (calendar.get (Calendar.YEAR));
buffer.append (temp.substring (temp.length() - 2));
}
else
OpenPOWER on IntegriCloud