3 #ifndef _VSTRING_VSTREAM_H_INCLUDED_
4 #define _VSTRING_VSTREAM_H_INCLUDED_
10 /* auto-resizing string library
12 /* #include <vstring_vstream.h>
24 extern int vstring_get(VSTRING
*, VSTREAM
*);
25 extern int vstring_get_nonl(VSTRING
*, VSTREAM
*);
26 extern int vstring_get_null(VSTRING
*, VSTREAM
*);
27 extern int vstring_get_bound(VSTRING
*, VSTREAM
*, ssize_t
);
28 extern int vstring_get_nonl_bound(VSTRING
*, VSTREAM
*, ssize_t
);
29 extern int vstring_get_null_bound(VSTRING
*, VSTREAM
*, ssize_t
);
32 * Backwards compatibility for code that still uses the vstring_fgets()
33 * interface. Unfortunately we can't change the macro name to upper case.
35 #define vstring_fgets(s, p) \
36 (vstring_get((s), (p)) == VSTREAM_EOF ? 0 : (s))
37 #define vstring_fgets_nonl(s, p) \
38 (vstring_get_nonl((s), (p)) == VSTREAM_EOF ? 0 : (s))
39 #define vstring_fgets_null(s, p) \
40 (vstring_get_null((s), (p)) == VSTREAM_EOF ? 0 : (s))
41 #define vstring_fgets_bound(s, p, l) \
42 (vstring_get_bound((s), (p), (l)) == VSTREAM_EOF ? 0 : (s))
43 #define vstring_fgets_nonl_bound(s, p, l) \
44 (vstring_get_nonl_bound((s), (p), (l)) == VSTREAM_EOF ? 0 : (s))
49 /* The Secure Mailer license must be distributed with this software.
52 /* IBM T.J. Watson Research
54 /* Yorktown Heights, NY 10598, USA