Commit f15e0a17 by Neil Booth Committed by Zack Weinberg

cccp.c (main): Check 'dir' for a NULL pointer before passing it to strcmp.

2000-02-04  Neil Booth  <NeilB@earthling.net>

	* cccp.c (main): Check 'dir' for a NULL pointer before passing
	it to strcmp.

From-SVN: r31802
parent 706b0f60
2000-02-04 Neil Booth <NeilB@earthling.net>
* cccp.c (main): Check 'dir' for a NULL pointer before passing
it to strcmp.
2000-02-04 Zack Weinberg <zack@wolery.cumb.org>
* recog.h: Remove NO_MD_PROTOTYPES ifdefs.
......
......@@ -1715,7 +1715,7 @@ main (argc, argv)
struct file_name_list *dirtmp;
char *dir = argv[i][2] ? argv[i] + 2 : argv[++i];
if (! ignore_srcdir && !strcmp (dir, "-")) {
if (! ignore_srcdir && dir && !strcmp (dir, "-")) {
ignore_srcdir = 1;
/* Don't use any preceding -I directories for #include <...>. */
first_bracket_include = 0;
......
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