Author: ambs
Date: Fri Jan 13 12:53:30 2006
New Revision: 11157

Modified:
   trunk/src/classes/file.pmc
Log:
File.pmc - corrected is_dir and is_file to use lstat instead of stat.


Modified: trunk/src/classes/file.pmc
==============================================================================
--- trunk/src/classes/file.pmc  (original)
+++ trunk/src/classes/file.pmc  Fri Jan 13 12:53:30 2006
@@ -64,7 +64,7 @@ Returns a true value (1) if the supplied
     METHOD INTVAL is_dir(STRING *path) {
         struct stat info;
         char *cpath = string_to_cstring(interpreter, path);
-        int error = stat(cpath, &info);
+        int error = lstat(cpath, &info);
         if (error) {
             char *errmsg = strerror(errno);
             real_exception(interpreter, NULL, E_SystemError, errmsg);
@@ -90,7 +90,7 @@ Returns a true value (1) if the supplied
     METHOD INTVAL is_file(STRING *path) {
         struct stat info;
         char *cpath = string_to_cstring(interpreter, path);
-        int error = stat(cpath, &info);
+        int error = lstat(cpath, &info);
         if (error) {
             char *errmsg = strerror(errno);
             real_exception(interpreter, NULL, E_SystemError, errmsg);

Reply via email to