src/pxar/sequential_decoder.rs: remove callback from new()
And use an extra functzion set_callback() to configure that. Also rewrite pxar/fuse.rs and implement a generic Session (will get further cleanups with next patches).
This commit is contained in:
		@ -31,7 +31,8 @@ impl PxarDecodeWriter {
 | 
			
		||||
        
 | 
			
		||||
        let child = thread::spawn(move|| {
 | 
			
		||||
            let mut reader = unsafe { std::fs::File::from_raw_fd(rx) };
 | 
			
		||||
            let mut decoder = pxar::SequentialDecoder::new(&mut reader, pxar::flags::DEFAULT, |path| {
 | 
			
		||||
            let mut decoder = pxar::SequentialDecoder::new(&mut reader, pxar::flags::DEFAULT);
 | 
			
		||||
            decoder.set_callback(move |path| {
 | 
			
		||||
                if verbose {
 | 
			
		||||
                    println!("{:?}", path);
 | 
			
		||||
                }
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user