docs(example): fix send file to only send range of buffer read into
This commit is contained in:
		
				
					committed by
					
						 Sean McArthur
						Sean McArthur
					
				
			
			
				
	
			
			
			
						parent
						
							586993fb2f
						
					
				
				
					commit
					73511ac8be
				
			| @@ -103,7 +103,7 @@ impl Service for ResponseExamples { | |||||||
|                                     tx_body.close().expect("panic closing"); |                                     tx_body.close().expect("panic closing"); | ||||||
|                                     break; |                                     break; | ||||||
|                                 } else { |                                 } else { | ||||||
|                                     let chunk: Chunk = buf.to_vec().into(); |                                     let chunk: Chunk = buf[0..n].to_vec().into(); | ||||||
|                                     match tx_body.send(Ok(chunk)).wait() { |                                     match tx_body.send(Ok(chunk)).wait() { | ||||||
|                                         Ok(t) => { tx_body = t; }, |                                         Ok(t) => { tx_body = t; }, | ||||||
|                                         Err(_) => { break; } |                                         Err(_) => { break; } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user