projects
/
sbcl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
0.8.10.57:
[sbcl.git]
/
contrib
/
sb-simple-streams
/
strategy.lisp
diff --git
a/contrib/sb-simple-streams/strategy.lisp
b/contrib/sb-simple-streams/strategy.lisp
index
ebbddf3
..
b080292
100644
(file)
--- a/
contrib/sb-simple-streams/strategy.lisp
+++ b/
contrib/sb-simple-streams/strategy.lisp
@@
-17,6
+17,7
@@
;;;; Helper functions
(defun refill-buffer (stream blocking)
;;;; Helper functions
(defun refill-buffer (stream blocking)
+ (declare (type blocking blocking))
(with-stream-class (simple-stream stream)
(let* ((unread (sm last-char-read-size stream))
(buffer (sm buffer stream))
(with-stream-class (simple-stream stream)
(let* ((unread (sm last-char-read-size stream))
(buffer (sm buffer stream))
@@
-140,7
+141,8
@@
(state (sm oc-state stream)))
(flet ((input ()
(when (>= buffpos (sm buffer-ptr stream))
(state (sm oc-state stream)))
(flet ((input ()
(when (>= buffpos (sm buffer-ptr stream))
- (when (sc-dirty-p stream)
+ (when (and (not (any-stream-instance-flags stream :dual :string))
+ (sc-dirty-p stream))
(flush-buffer stream t))
(let ((bytes (refill-buffer stream blocking)))
(cond ((= bytes 0)
(flush-buffer stream t))
(let ((bytes (refill-buffer stream blocking)))
(cond ((= bytes 0)
@@
-216,7
+218,8
@@
(type boolean blocking)
#|(optimize (speed 3) (space 2) (safety 0) (debug 0))|#)
(with-stream-class (simple-stream stream)
(type boolean blocking)
#|(optimize (speed 3) (space 2) (safety 0) (debug 0))|#)
(with-stream-class (simple-stream stream)
- (when (sc-dirty-p stream)
+ (when (and (not (any-stream-instance-flags stream :dual :string))
+ (sc-dirty-p stream))
(flush-buffer stream t))
(do ((buffer (sm buffer stream))
(buffpos (sm buffpos stream))
(flush-buffer stream t))
(do ((buffer (sm buffer stream))
(buffpos (sm buffpos stream))