16 lines
453 B
Text
16 lines
453 B
Text
|
$NetBSD: patch-ac,v 1.3 2008/05/13 22:30:47 tonnerre Exp $
|
||
|
|
||
|
--- lib/stream.h
|
||
|
+++ lib/stream.h
|
||
|
@@ -59,7 +59,9 @@ struct stream_fifo
|
||
|
#define STREAM_SIZE(S) ((S)->size)
|
||
|
#define STREAM_REMAIN(S) ((S)->size - (S)->putp)
|
||
|
#define STREAM_DATA(S) ((S)->data)
|
||
|
-
|
||
|
+/* number of bytes still to be read */
|
||
|
+#define STREAM_READABLE(S) ((S)->endp - (S)->getp)
|
||
|
+
|
||
|
/* Stream prototypes. */
|
||
|
struct stream *stream_new (size_t);
|
||
|
void stream_free (struct stream *);
|