diff options
author | Marius Vollmer <mvo@zagadka.de> | 2004-08-12 17:03:36 +0000 |
---|---|---|
committer | Marius Vollmer <mvo@zagadka.de> | 2004-08-12 17:03:36 +0000 |
commit | d617ee1895503e4b85da9fa72fcafb7a3b79951d (patch) | |
tree | 990d36145c8894014b6088d752d87e9deae47ac7 /libguile/vports.c | |
parent | ffa747a6ead5e8ba3c6af1fc26c4bbaa72e2d72b (diff) | |
download | guile-d617ee1895503e4b85da9fa72fcafb7a3b79951d.tar.gz |
* fports.h, fports.c (scm_i_fdes_to_port): New, like
scm_fdes_to_port, but take mode bits directly instead of as a C
string.
(scm_i_fdes_to_port): Implement using above.
(scm_open_file): Use scm_i_fdes_to_port together with
scm_i_mode_bits to avoid accessing internals of SCM string from C.
* vports.c (scm_make_soft_port): Use scm_i_fdes_to_port together
with scm_i_mode_bits to avoid accessing internals of SCM string
from C.
* ports.h (scm_i_mode_bits): New, same as scm_mode_bits but with a
SCM string as argument.
* ports.c (scm_i_void_port): New, like scm_void_port but take mode
bits directly instead of C string.
(scm_void_port): Implement using above.
(scm_sys_make_void_port): Use scm_i_void_port together with
scm_i_mode_bits to avoid accessing internals of SCM string.
* convert.i.c, backtrace.c, strop.c, strorder.c, strports.c,
struct.c, unif.c, ports.c: Use SCM_I_STRING_CHARS,
SCM_I_STRING_UCHARS, and SCM_I_STRING_LENGTH instead of
SCM_STRING_CHARS, SCM_STRING_UCHARS, and SCM_STRING_LENGTH,
respectively. Also, replaced scm_return_first with more explicit
scm_remember_upto_here_1, etc, or introduced them in the first
place.
Diffstat (limited to 'libguile/vports.c')
-rw-r--r-- | libguile/vports.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libguile/vports.c b/libguile/vports.c index 096b26c7f..e99d7961c 100644 --- a/libguile/vports.c +++ b/libguile/vports.c @@ -196,7 +196,7 @@ SCM_DEFINE (scm_make_soft_port, "make-soft-port", 2, 0, 0, z = scm_new_port_table_entry (scm_tc16_sfport); pt = SCM_PTAB_ENTRY (z); scm_port_non_buffer (pt); - SCM_SET_CELL_TYPE (z, scm_tc16_sfport | scm_mode_bits (SCM_STRING_CHARS (modes))); + SCM_SET_CELL_TYPE (z, scm_tc16_sfport | scm_i_mode_bits (modes)); SCM_SETSTREAM (z, SCM_UNPACK (pv)); scm_mutex_unlock (&scm_i_port_table_mutex); |