mirror of
				https://github.com/python/cpython.git
				synced 2025-10-25 02:43:41 +00:00 
			
		
		
		
	Use AttributeError.
This commit is contained in:
		
							parent
							
								
									aa3760d91d
								
							
						
					
					
						commit
						470e7617a9
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -95,7 +95,7 @@ def isdir(path): | ||||||
| def islink(path): | def islink(path): | ||||||
| 	try: | 	try: | ||||||
| 		st = posix.lstat(path) | 		st = posix.lstat(path) | ||||||
| 	except (posix.error, NameError): | 	except (posix.error, AttributeError): | ||||||
| 		return 0 | 		return 0 | ||||||
| 	return stat.S_ISLNK(st[stat.ST_MODE]) | 	return stat.S_ISLNK(st[stat.ST_MODE]) | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Guido van Rossum
						Guido van Rossum