diff options
author | jsorg71 <jsorg71> | 2009-04-19 22:55:03 +0000 |
---|---|---|
committer | jsorg71 <jsorg71> | 2009-04-19 22:55:03 +0000 |
commit | da9934395772c727968e3a67eed13231bc9ec607 (patch) | |
tree | a122b3a1e3560c002f73abceaa3e797fd5acc5d1 | |
parent | 06e40d9304e4f6d330c4b003e3b343b9ce0e44e1 (diff) | |
download | xrdp-proprietary-da9934395772c727968e3a67eed13231bc9ec607.tar.gz xrdp-proprietary-da9934395772c727968e3a67eed13231bc9ec607.zip |
fixes for chansrv
-rw-r--r-- | xrdp/xrdp_mm.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/xrdp/xrdp_mm.c b/xrdp/xrdp_mm.c index af7d1795..13100923 100644 --- a/xrdp/xrdp_mm.c +++ b/xrdp/xrdp_mm.c @@ -513,10 +513,10 @@ xrdp_mm_trans_send_channel_setup(struct xrdp_mm* self, struct trans* trans) s_push_layer(s, mcs_hdr, 8); s_push_layer(s, sec_hdr, 2); index = 0; - while (server_query_channel(self->mod, index, chan_name, - &chan_flags) == 0) + while (libxrdp_query_channel(self->wm->session, index, chan_name, + &chan_flags) == 0) { - chan_id = server_get_channel_id(self->mod, chan_name); + chan_id = libxrdp_get_channel_id(self->wm->session, chan_name); out_uint8a(s, chan_name, 8); out_uint16_le(s, chan_id); out_uint16_le(s, chan_flags); @@ -591,8 +591,8 @@ xrdp_mm_trans_process_channel_data(struct xrdp_mm* self, struct trans* trans) rv = xrdp_mm_trans_send_channel_data_response(self, trans); if (rv == 0) { - rv = server_send_to_channel(self->mod, chan_id, s->p, size, total_size, - chan_flags); + rv = libxrdp_send_to_channel(self->wm->session, chan_id, s->p, size, total_size, + chan_flags); } return rv; } @@ -1294,6 +1294,7 @@ server_query_channel(struct xrdp_mod* mod, int index, char* channel_name, } /*****************************************************************************/ +/* returns -1 on error */ int DEFAULT_CC server_get_channel_id(struct xrdp_mod* mod, char* name) { @@ -1302,7 +1303,7 @@ server_get_channel_id(struct xrdp_mod* mod, char* name) wm = (struct xrdp_wm*)mod->wm; if (wm->mm->sesman_controlled) { - return 1; + return -1; } return libxrdp_get_channel_id(wm->session, name); } |