@@ -324,7 +324,7 @@ impl<K: Key, T: Transport, H: MessageHandler<T>> ConnInner<K, T, H> {
324
324
}
325
325
} ;
326
326
let mut head = http:: MessageHead :: default ( ) ;
327
- let interest = handler. on_outgoing ( & mut head) ;
327
+ let mut interest = handler. on_outgoing ( & mut head) ;
328
328
if head. version == HttpVersion :: Http11 {
329
329
let mut buf = Vec :: new ( ) ;
330
330
let keep_alive = self . keep_alive_enabled && head. should_keep_alive ( ) ;
@@ -339,6 +339,7 @@ impl<K: Key, T: Transport, H: MessageHandler<T>> ConnInner<K, T, H> {
339
339
bytes : buf,
340
340
pos : 0
341
341
} ) ;
342
+ interest = handler. on_encode ( & mut Encoder :: h1 ( & mut encoder, & mut self . transport ) ) ;
342
343
Writing :: Ready ( encoder)
343
344
} ,
344
345
_ => Writing :: Chunk ( Chunk {
@@ -370,7 +371,7 @@ impl<K: Key, T: Transport, H: MessageHandler<T>> ConnInner<K, T, H> {
370
371
}
371
372
Writing :: Head => {
372
373
let mut head = http:: MessageHead :: default ( ) ;
373
- let interest = handler. on_outgoing ( & mut head) ;
374
+ let mut interest = handler. on_outgoing ( & mut head) ;
374
375
// if the request wants to close, server cannot stop it
375
376
if * keep_alive {
376
377
// if the request wants to stay alive, then it depends
@@ -389,6 +390,7 @@ impl<K: Key, T: Transport, H: MessageHandler<T>> ConnInner<K, T, H> {
389
390
bytes : buf,
390
391
pos : 0
391
392
} ) ;
393
+ interest = handler. on_encode ( & mut Encoder :: h1 ( & mut encoder, & mut self . transport ) ) ;
392
394
Writing :: Ready ( encoder)
393
395
} ,
394
396
_ => Writing :: Chunk ( Chunk {
0 commit comments