Mercurial > hg > xemacs-beta
diff src/lstream.h @ 5795:d2c0ff38ad5c
Report lstream errors when encoding/decoding.
See <CAHCOHQ=FAieD-2nP303fMvwkii8HK2z+X7gRZ2+4PH1CA5_-NA@mail.gmail.com> in
xemacs-patches.
author | Jerry James <james@xemacs.org> |
---|---|
date | Wed, 14 May 2014 14:16:24 -0600 |
parents | 65d65b52d608 |
children | a216b3c2b09e |
line wrap: on
line diff
--- a/src/lstream.h Wed May 07 13:33:50 2014 -0600 +++ b/src/lstream.h Wed May 14 14:16:24 2014 -0600 @@ -174,6 +174,10 @@ in an attempt to block (EWOULDBLOCK). If this method does not exists, the implementation returns 0 */ int (*was_blocked_p) (Lstream *stream); + /* If the reader or writer method returned LSTREAM_ERROR, the errno + associated with the error, or zero if there was no system error or this + method is not implemented. */ + int (*error) (Lstream *stream); /* Rewind the stream. If this is NULL, the stream is not seekable. */ int (*rewinder) (Lstream *stream); /* Indicate whether this stream is seekable -- i.e. it can be rewound. @@ -306,6 +310,7 @@ Charcount Lstream_character_tell (Lstream *); int Lstream_write (Lstream *lstr, const void *data, Bytecount size); +int Lstream_errno (Lstream *lstr); int Lstream_was_blocked_p (Lstream *lstr); void Lstream_unread (Lstream *lstr, const void *data, Bytecount size); int Lstream_rewind (Lstream *lstr);