Skip to content
Snippets Groups Projects
Commit 6016d9fc authored by Houtan Bastani's avatar Houtan Bastani
Browse files

preprocessor: fix bug introduced in 1ba04976. #1039

parent c9a808f7
No related branches found
No related tags found
No related merge requests found
...@@ -401,7 +401,8 @@ MacroFlex::create_include_context(string *filename, Macro::parser::location_type ...@@ -401,7 +401,8 @@ MacroFlex::create_include_context(string *filename, Macro::parser::location_type
dirs << "." << FILESEP << endl; dirs << "." << FILESEP << endl;
for (vector<string>::const_iterator it = path.begin(); it != path.end(); it++) for (vector<string>::const_iterator it = path.begin(); it != path.end(); it++)
{ {
input = new ifstream(it->c_str() + FILESEP + filename->c_str(), ios::binary); string testfile = *it + FILESEP + *filename;
input = new ifstream(testfile.c_str(), ios::binary);
if (input->good()) if (input->good())
break; break;
dirs << *it << endl; dirs << *it << endl;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment