changed: #next:
authorStefan Vogel <sv@exept.de>
Thu, 17 Dec 2009 16:52:07 +0100
changeset 12623 389426d8f6eb
parent 12622 364dcd203682
child 12624 6caeb35528b4
changed: #next: if proceeding from EndOfStreamError, do not put nil onto character stream
Stream.st
--- a/Stream.st	Thu Dec 17 12:46:36 2009 +0100
+++ b/Stream.st	Thu Dec 17 16:52:07 2009 +0100
@@ -194,7 +194,6 @@
     ^ ChunkSeparator
 ! !
 
-
 !Stream methodsFor:'accessing'!
 
 contents
@@ -1941,6 +1940,8 @@
         next isNil ifTrue:[
             "if next did not raise EndOfStreamError, we have to do it"
             EndOfStreamError raiseRequestFrom:self.
+            "if you proceed, you get what we have already collected"
+            ^ answerStream contents
         ].
         answerStream nextPut:next.
     ].
@@ -2538,6 +2539,7 @@
     "Modified: / 19.5.1998 / 17:26:25 / cg"
 ! !
 
+
 !Stream methodsFor:'testing'!
 
 atEnd
@@ -3127,11 +3129,11 @@
 !Stream class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/Stream.st,v 1.184 2009-11-15 09:55:42 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Stream.st,v 1.185 2009-12-17 15:52:07 stefan Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic/Stream.st,v 1.184 2009-11-15 09:55:42 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Stream.st,v 1.185 2009-12-17 15:52:07 stefan Exp $'
 ! !
 
 Stream initialize!