Filter chars under \x20
This commit is contained in:
		
							parent
							
								
									6e7abd7406
								
							
						
					
					
						commit
						e5bf232253
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -336,7 +336,7 @@ def ConvertToFile(filename_or_file, *args, **kwargs): | ||||||
| 
 | 
 | ||||||
| def FilterBadChars(f): | def FilterBadChars(f): | ||||||
|     s = f.read() |     s = f.read() | ||||||
|     s = re.sub('[\\x00-\\x19]', '\ufffd', s) |     s = re.sub('[\\x00-\\x08\\x0b\\x0c\\x0e-\\x1f]', '\ufffd', s) | ||||||
|     return io.StringIO(s) |     return io.StringIO(s) | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Star Brilliant
						Star Brilliant