summaryrefslogtreecommitdiff
path: root/java/io/ObjectInputStream.java
diff options
context:
space:
mode:
Diffstat (limited to 'java/io/ObjectInputStream.java')
-rw-r--r--java/io/ObjectInputStream.java12
1 files changed, 8 insertions, 4 deletions
diff --git a/java/io/ObjectInputStream.java b/java/io/ObjectInputStream.java
index 50ae29d74..fc3795696 100644
--- a/java/io/ObjectInputStream.java
+++ b/java/io/ObjectInputStream.java
@@ -331,6 +331,14 @@ public class ObjectInputStream extends InputStream
boolean oldmode = setBlockDataMode(true);
callReadMethod(readObjectMethod, this.currentObjectStreamClass.forClass(), obj);
setBlockDataMode(oldmode);
+ }
+ else
+ {
+ readFields(obj, currentObjectStreamClass);
+ }
+
+ if (this.currentObjectStreamClass.hasWriteMethod())
+ {
if(dump) dumpElement("ENDBLOCKDATA? ");
try
{
@@ -353,10 +361,6 @@ public class ObjectInputStream extends InputStream
if(dump) dumpElementln("no, got IOException");
}
}
- else
- {
- readFields(obj, currentObjectStreamClass);
- }
}
this.currentObject = prevObject;