Commit b6464a73 by Neil Booth Committed by Neil Booth

cppfiles.c (INCLUDE_LEN_FUDGE, ENOMEM): Delete.

        * cppfiles.c (INCLUDE_LEN_FUDGE, ENOMEM): Delete.
	(cpp_included, find_include_file): Update.
	(_cpp_compare_file_date): Make else unconditional.

From-SVN: r40388
parent a72ac6ef
2001-03-11 Neil Booth <neil@daikokuya.demon.co.uk>
* cppfiles.c (INCLUDE_LEN_FUDGE, ENOMEM): Delete.
(cpp_included, find_include_file): Update.
(_cpp_compare_file_date): Make else unconditional.
2001-03-10 kaz Kojima <kkojima@rr.iij4u.or.jp> 2001-03-10 kaz Kojima <kkojima@rr.iij4u.or.jp>
* config/sh/sh.h (LEGITIMATE_PIC_OPERAND_P): Defined. * config/sh/sh.h (LEGITIMATE_PIC_OPERAND_P): Defined.
......
...@@ -43,10 +43,6 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ ...@@ -43,10 +43,6 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
# define O_BINARY 0 # define O_BINARY 0
#endif #endif
#ifndef INCLUDE_LEN_FUDGE
# define INCLUDE_LEN_FUDGE 0
#endif
/* If errno is inspected immediately after a system call fails, it will be /* If errno is inspected immediately after a system call fails, it will be
nonzero, and no error number will ever be zero. */ nonzero, and no error number will ever be zero. */
#ifndef ENOENT #ifndef ENOENT
...@@ -55,9 +51,6 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ ...@@ -55,9 +51,6 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef ENOTDIR #ifndef ENOTDIR
# define ENOTDIR 0 # define ENOTDIR 0
#endif #endif
#ifndef ENOMEM
# define ENOMEM 0
#endif
/* Suppress warning about function macros used w/o arguments in traditional /* Suppress warning about function macros used w/o arguments in traditional
C. It is unlikely that glibc's strcmp macro helps this file at all. */ C. It is unlikely that glibc's strcmp macro helps this file at all. */
...@@ -469,8 +462,7 @@ cpp_included (pfile, fname) ...@@ -469,8 +462,7 @@ cpp_included (pfile, fname)
} }
/* Search directory path for the file. */ /* Search directory path for the file. */
name = (char *) alloca (strlen (fname) + pfile->max_include_len name = (char *) alloca (strlen (fname) + pfile->max_include_len + 2);
+ 2 + INCLUDE_LEN_FUDGE);
for (path = CPP_OPTION (pfile, quote_include); path; path = path->next) for (path = CPP_OPTION (pfile, quote_include); path; path = path->next)
{ {
memcpy (name, path->name, path->len); memcpy (name, path->name, path->len);
...@@ -505,8 +497,7 @@ find_include_file (pfile, fname, search_start) ...@@ -505,8 +497,7 @@ find_include_file (pfile, fname, search_start)
return open_file (pfile, fname); return open_file (pfile, fname);
/* Search directory path for the file. */ /* Search directory path for the file. */
name = (char *) alloca (strlen (fname) + pfile->max_include_len name = (char *) alloca (strlen (fname) + pfile->max_include_len + 2);
+ 2 + INCLUDE_LEN_FUDGE);
for (path = search_start; path; path = path->next) for (path = search_start; path; path = path->next)
{ {
memcpy (name, path->name, path->len); memcpy (name, path->name, path->len);
...@@ -723,7 +714,7 @@ _cpp_compare_file_date (pfile, f) ...@@ -723,7 +714,7 @@ _cpp_compare_file_date (pfile, f)
if (f->type == CPP_HEADER_NAME) if (f->type == CPP_HEADER_NAME)
search_start = CPP_OPTION (pfile, bracket_include); search_start = CPP_OPTION (pfile, bracket_include);
else if (CPP_OPTION (pfile, ignore_srcdir)) else
search_start = pfile->buffer->search_from; search_start = pfile->buffer->search_from;
inc = find_include_file (pfile, fname, search_start); inc = find_include_file (pfile, fname, search_start);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment