1
0
mirror of https://github.com/moparisthebest/spdylay synced 2024-12-22 15:48:53 -05:00

Call on_ctrl_send_callback and before_ctrl_send_callback for WINDOW_UPDATE.

This commit is contained in:
Tatsuhiro Tsujikawa 2012-03-30 00:14:20 +09:00
parent 90c2739a9c
commit 169857742b

View File

@ -1033,8 +1033,7 @@ static int spdylay_session_after_frame_sent(spdylay_session *session)
spdylay_frame_type type;
frame = spdylay_outbound_item_get_ctrl_frame(session->aob.item);
type = spdylay_outbound_item_get_ctrl_frame_type(session->aob.item);
if(session->callbacks.on_ctrl_send_callback &&
type != SPDYLAY_WINDOW_UPDATE) {
if(session->callbacks.on_ctrl_send_callback) {
session->callbacks.on_ctrl_send_callback
(session, type, frame, session->user_data);
}
@ -1269,15 +1268,11 @@ int spdylay_session_send(spdylay_session *session)
/* Call before_send callback */
if(item->frame_cat == SPDYLAY_CTRL &&
session->callbacks.before_ctrl_send_callback) {
spdylay_frame_type frame_type;
frame_type = spdylay_outbound_item_get_ctrl_frame_type(item);
if(frame_type != SPDYLAY_WINDOW_UPDATE) {
session->callbacks.before_ctrl_send_callback
(session,
frame_type,
spdylay_outbound_item_get_ctrl_frame(item),
session->user_data);
}
session->callbacks.before_ctrl_send_callback
(session,
spdylay_outbound_item_get_ctrl_frame_type(item),
spdylay_outbound_item_get_ctrl_frame(item),
session->user_data);
}
}
data = session->aob.framebuf + session->aob.framebufoff;