From dad362764fe456881661e192c595a6774794eb82 Mon Sep 17 00:00:00 2001 From: Matt Kraai Date: Mon, 30 Apr 2001 23:09:39 +0000 Subject: [PATCH] natFile.cc (performSetReadOnly): Fix #ifdef test. 2001-04-30 Matt Kraai * java/io/natFile.cc (performSetReadOnly): Fix #ifdef test. (performDelete): Fix #endif placement. From-SVN: r41703 --- libjava/ChangeLog | 5 +++++ libjava/java/io/natFile.cc | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 2ce678a4df9..0c144a09b77 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,8 @@ +2001-04-30 Matt Kraai + + * java/io/natFile.cc (performSetReadOnly): Fix #ifdef test. + (performDelete): Fix #endif placement. + 2001-04-27 Zack Weinberg * prims.cc (_Jv_ThisExecutable): Use _Jv_Malloc. diff --git a/libjava/java/io/natFile.cc b/libjava/java/io/natFile.cc index 89cdec6ebeb..6fa46c00410 100644 --- a/libjava/java/io/natFile.cc +++ b/libjava/java/io/natFile.cc @@ -227,7 +227,7 @@ java::io::File::performSetReadOnly (void) // FIXME? buf[total] = '\0'; -#ifdef HAVE_STAT && HAVE_CHMOD +#if defined (HAVE_STAT) && defined (HAVE_CHMOD) struct stat sb; if (::stat (buf, &sb)) return false; @@ -328,8 +328,8 @@ java::io::File::performDelete (void) #ifdef HAVE_RMDIR if (! ::rmdir (buf)) return true; -#endif // HAVE_RMDIR if (errno == ENOTDIR) +#endif // HAVE_RMDIR return ::unlink (buf) == 0; #endif // HAVE_UNLINK return false;