From a591389de3f259e0c608bcf8fcacd94cc79fe0b6 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Fri, 21 Oct 2005 14:08:19 +0000 Subject: [PATCH] * dir.cc (rmdir): Eliminate nonsensical code. * fork.cc (fork): Move exit debug_printf to last statement. --- winsup/cygwin/ChangeLog | 6 ++++++ winsup/cygwin/dir.cc | 5 +---- winsup/cygwin/fork.cc | 2 +- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 5a11ce6c8..ad8902949 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,9 @@ +2005-10-21 Christopher Faylor + + * dir.cc (rmdir): Eliminate nonsensical code. + + * fork.cc (fork): Move exit debug_printf to last statement. + 2005-10-20 Corinna Vinschen * cygwin.din (futimes): Export. diff --git a/winsup/cygwin/dir.cc b/winsup/cygwin/dir.cc index 0d25619b9..6faddf37b 100644 --- a/winsup/cygwin/dir.cc +++ b/winsup/cygwin/dir.cc @@ -305,10 +305,7 @@ rmdir (const char *dir) if (fh->error ()) { debug_printf ("got %d error from build_fh_name", fh->error ()); - if (fh->error ()) - set_errno (EROFS); - else - set_errno (fh->error ()); + set_errno (fh->error ()); } else if (!fh->rmdir ()) res = 0; diff --git a/winsup/cygwin/fork.cc b/winsup/cygwin/fork.cc index 3381d128d..13cccba3e 100644 --- a/winsup/cygwin/fork.cc +++ b/winsup/cygwin/fork.cc @@ -601,8 +601,8 @@ fork () set_errno (grouped.this_errno); } - syscall_printf ("%d = fork()", res); sig_send (NULL, __SIGNOHOLD); + syscall_printf ("%d = fork()", res); return res; } #ifdef DEBUGGING