File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -118,6 +118,7 @@ where
118
118
} ;
119
119
120
120
let mut rewriter = HtmlRewriter :: new( settings, move |chunk: & [ u8 ] | {
121
+ // this can fail only when the receiver is dropped.
121
122
let _ = result_sender. send( Bytes :: from( chunk. to_vec( ) ) ) ;
122
123
} ) ;
123
124
while let Some ( chunk) = data_receiver. recv( ) ? {
@@ -134,7 +135,7 @@ where
134
135
loop {
135
136
let n = match reader. read( & mut read_buf) . await {
136
137
Ok ( 0 ) => {
137
- // this should get the background thread to exit
138
+ // This signals the renderer thread to finalize & exit.
138
139
data_sender. send( None ) . unwrap( ) ;
139
140
break ;
140
141
}
@@ -146,7 +147,7 @@ where
146
147
}
147
148
} ;
148
149
if let Err ( err) = data_sender. send( Some ( read_buf[ ..n] . to_vec( ) ) ) {
149
- // reveiver was dropped?
150
+ // FIXME: reveiver was dropped? do we care about that ?
150
151
yield Err ( RewritingError :: ContentHandlerError ( err. into( ) ) ) ;
151
152
break ;
152
153
}
You can’t perform that action at this time.
0 commit comments