summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libguile-ssh/channel-type.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/libguile-ssh/channel-type.c b/libguile-ssh/channel-type.c
index 323e0d6..1c63c6c 100644
--- a/libguile-ssh/channel-type.c
+++ b/libguile-ssh/channel-type.c
@@ -183,12 +183,9 @@ print_channel (SCM channel, SCM port, scm_print_state *pstate)
{
struct channel_data *ch = _scm_to_channel_data (channel);
- if (SCM_INPUT_PORT_P (port) && SCM_OUTPUT_PORT_P (port))
- scm_puts ("#<channel ", port);
- else if (SCM_INPUT_PORT_P (port))
- scm_puts ("#<input channel ", port);
- else if (SCM_OUTPUT_PORT_P (port))
- scm_puts ("#<output channel ", port);
+ scm_puts ("#<", port);
+ scm_print_port_mode (channel, port);
+ scm_puts ("channel ", port);
if (! ch)
{