* dir.cc (rmdir): Use file attributes that have already been discovered by
path_conv.
This commit is contained in:
		
							parent
							
								
									7e06494e35
								
							
						
					
					
						commit
						4b62cff84c
					
				| 
						 | 
				
			
			@ -1,4 +1,4 @@
 | 
			
		|||
Thu May 25 17:01:53 2000  Christopher Faylor <cgf@cygnus.com>
 | 
			
		||||
Thu May 25 17:44:25 2000  Christopher Faylor <cgf@cygnus.com>
 | 
			
		||||
 | 
			
		||||
	* dir.cc (rmdir): Use file attributes that have already been discovered
 | 
			
		||||
	by path_conv.
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -341,7 +341,8 @@ rmdir (const char *dir)
 | 
			
		|||
      /* Under Windows 9X or on a samba share, ERROR_ACCESS_DENIED is
 | 
			
		||||
         returned if you try to remove a file. On 9X the same error is
 | 
			
		||||
         returned if you try to remove a non-empty directory. */
 | 
			
		||||
     if (real_dir.file_attributes () != (DWORD) -1 && !(real_dir.fileattr & FILE_ATTRIBUTE_DIRECTORY))
 | 
			
		||||
     if (real_dir.file_attributes () != (DWORD) -1 &&
 | 
			
		||||
	 !(real_dir.file_attributes () & FILE_ATTRIBUTE_DIRECTORY))
 | 
			
		||||
       set_errno (ENOTDIR);
 | 
			
		||||
     else if (os_being_run != winNT)
 | 
			
		||||
       set_errno (ENOTEMPTY);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue