Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
LSH
lsh
Commits
a4114d06
Commit
a4114d06
authored
Aug 27, 2002
by
Niels Möller
Browse files
(channel_data_handler,
channel_extended_data_handler): Use lsh_string_trunc. Rev: src/channel.c:1.114
parent
daff509c
Changes
1
Show whitespace changes
Inline
Side-by-side
src/channel.c
View file @
a4114d06
...
...
@@ -1208,7 +1208,7 @@ DEFINE_PACKET_HANDLER(static, channel_data_handler,
if
(
data
->
length
>
channel
->
rec_max_packet
)
{
werror
(
"Channel data larger than rec_max_packet. Extra data ignored.
\n
"
);
data
->
length
=
channel
->
rec_max_packet
;
lsh_string_trunc
(
data
,
channel
->
rec_max_packet
)
;
}
if
(
data
->
length
>
channel
->
rec_window_size
)
...
...
@@ -1218,7 +1218,7 @@ DEFINE_PACKET_HANDLER(static, channel_data_handler,
debug
(
" (data->length=%i, rec_window_size=%i).
\n
"
,
data
->
length
,
channel
->
rec_window_size
);
data
->
length
=
channel
->
rec_window_size
;
lsh_string_trunc
(
data
,
channel
->
rec_window_size
)
;
}
if
(
!
data
->
length
)
...
...
@@ -1279,7 +1279,7 @@ DEFINE_PACKET_HANDLER(static, channel_extended_data_handler,
if
(
data
->
length
>
channel
->
rec_max_packet
)
{
werror
(
"Channel data larger than rec_max_packet. Extra data ignored.
\n
"
);
data
->
length
=
channel
->
rec_max_packet
;
lsh_string_trunc
(
data
,
channel
->
rec_max_packet
)
;
}
if
(
data
->
length
>
channel
->
rec_window_size
)
...
...
@@ -1289,7 +1289,8 @@ DEFINE_PACKET_HANDLER(static, channel_extended_data_handler,
"Extra data ignored.
\n
"
);
debug
(
" (data->length=%i, rec_window_size=%i).
\n
"
,
data
->
length
,
channel
->
rec_window_size
);
data
->
length
=
channel
->
rec_window_size
;
lsh_string_trunc
(
data
,
channel
->
rec_window_size
);
}
if
(
!
data
->
length
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment