delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT sourceware DOT cygnus DOT com> |
List-Subscribe: | <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com> |
List-Archive: | <http://sourceware.cygnus.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT sourceware DOT cygnus DOT com> |
List-Help: | <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs> |
Sender: | cygwin-owner AT sourceware DOT cygnus DOT com |
Delivered-To: | mailing list cygwin AT sourceware DOT cygnus DOT com |
To: | cygwin AT sourceware DOT cygnus DOT com |
Subject: | PATCH for winsup/dir.cc |
From: | Guy Maor <gmaor AT wlv DOT hp DOT com> |
Date: | 14 Sep 1999 11:40:04 -0700 |
Message-ID: | <u40puzlibgb.fsf@goleta.wlv.hp.com> |
Lines: | 21 |
User-Agent: | Gnus/5.070092 (Pterodactyl Gnus v0.92) XEmacs/20.4 (Emerald) |
MIME-Version: | 1.0 |
Here is a patch to winsup/dir.cc which fixes rmdir() errno codes on Win 95/98. It's a pretty straightforward fix. --- dir.cc.orig Tue Sep 14 11:29:36 1999 +++ dir.cc Tue Aug 31 11:20:26 1999 @@ -331,11 +300,14 @@ else if (os_being_run != winNT && GetLastError() == ERROR_ACCESS_DENIED) { /* Under Windows 95 & 98, ERROR_ACCESS_DENIED is returned - if you try to remove a directory that is not empty. */ - set_errno (ENOTEMPTY); + if you try to remove a file or a non-empty directory. */ + if (GetFileAttributes (real_dir.get_win32()) != FILE_ATTRIBUTE_DIRECTORY) + set_errno (ENOTDIR); + else + set_errno (ENOTEMPTY); } I'm not subscribed to the cygwin list, so please cc me on any replies. Guy -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |