Add path implementation to rand
This commit is contained in:
		
							parent
							
								
									39e56db812
								
							
						
					
					
						commit
						1664f6cf03
					
				
					 1 changed files with 10 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -42,6 +42,16 @@ impl SchemeMut for RandScheme {
 | 
			
		|||
        Ok(i)
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    fn fpath(&mut self, _file: usize, buf: &mut [u8]) -> Result<usize> {
 | 
			
		||||
        let mut i = 0;
 | 
			
		||||
        let scheme_path = b"rand";
 | 
			
		||||
        while i < buf.len() && i < scheme_path.len() {
 | 
			
		||||
            buf[i] = scheme_path[i];
 | 
			
		||||
            i += 1;
 | 
			
		||||
        }
 | 
			
		||||
        Ok(i)
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    fn close(&mut self, _file: usize) -> Result<usize> {
 | 
			
		||||
        Ok(0)
 | 
			
		||||
    }
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue