@@ -4,6 +4,7 @@ use crate::{
44    setters, 
55} ; 
66use  futures:: { task:: Poll ,  Future } ; 
7+ use  log:: debug; 
78use  std:: { cmp:: min,  io:: SeekFrom ,  pin:: Pin ,  sync:: Arc ,  task:: Context } ; 
89use  tokio:: { 
910    fs:: File , 
@@ -99,7 +100,7 @@ impl FileStream {
99100/// 
100101/// This is useful if you want to read the stream in multiple blocks 
101102pub  async  fn  next_block ( & mut  self )  -> crate :: Result < ( ) >  { 
102-         log :: info !( "setting limit to {}" ,  self . block_size) ; 
103+         debug ! ( "setting limit to {}" ,  self . block_size) ; 
103104        let  mut  handle = self . handle . clone ( ) . lock_owned ( ) . await ; 
104105        { 
105106            let  inner = handle. get_mut ( ) ; 
@@ -117,10 +118,9 @@ impl SeekableStream for FileStream {
117118/// 
118119/// This is useful upon encountering an error to reset the stream to the last 
119120async  fn  reset ( & mut  self )  -> crate :: Result < ( ) >  { 
120-         log :: info !( 
121+         debug ! ( 
121122            "resetting stream to offset {} and limit to {}" , 
122-             self . offset, 
123-             self . block_size
123+             self . offset,  self . block_size
124124        ) ; 
125125        let  mut  handle = self . handle . clone ( ) . lock_owned ( ) . await ; 
126126        { 
@@ -132,11 +132,9 @@ impl SeekableStream for FileStream {
132132    } 
133133
134134    fn  len ( & self )  -> usize  { 
135-         log :: info !( 
135+         debug ! ( 
136136            "stream len:  {} - {} ... {}" , 
137-             self . stream_size, 
138-             self . offset, 
139-             self . block_size
137+             self . stream_size,  self . offset,  self . block_size
140138        ) ; 
141139        min ( self . stream_size  - self . offset ,  self . block_size )  as  usize 
142140    } 
0 commit comments