Better error messages when opening include files
git-svn-id: svn://svn.cc65.org/cc65/trunk@83 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -38,7 +38,6 @@
|
||||
#if defined(_MSC_VER)
|
||||
/* Microsoft compiler */
|
||||
# include <io.h>
|
||||
# define R_OK 4
|
||||
#else
|
||||
/* Anyone else */
|
||||
# include <unistd.h>
|
||||
@@ -137,10 +136,10 @@ static char* Find (const char* Path, const char* File)
|
||||
strcpy (PathName + Count, File);
|
||||
|
||||
/* Check if this file exists */
|
||||
if (access (PathName, R_OK) == 0) {
|
||||
if (access (PathName, 0) == 0) {
|
||||
/* The file exists */
|
||||
return xstrdup (PathName);
|
||||
}
|
||||
}
|
||||
|
||||
/* Skip a list separator if we have one */
|
||||
if (*P == ';') {
|
||||
|
||||
Reference in New Issue
Block a user