commit d9031e5d8194fda970b2c7f58ef92b40577480b4
parent e2e0a88e3801bf093c3216b6648c8437b2fcccbc
Author: Kyle Milz <kyle@getaddrinfo.net>
Date: Sun, 13 Mar 2016 19:01:37 -0600
instrument: match *.cxx files too
Diffstat:
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/instrument/main.cxx b/instrument/main.cxx
@@ -114,10 +114,11 @@ main(int argc, char *argv[])
real_compiler_argv[i] = argv[i];
// Dirty hack to find source files
- if (ends_with(arg, ".cpp") || ends_with(arg, ".c")) {
+ if (ends_with(arg, ".cpp") || ends_with(arg, ".c")
+ || ends_with(arg, ".cxx")) {
+
// Keep track of original source file names
source_files.push_back(arg);
- std::string inst_src_path;
// Find original directory or "." if relative path
char *src_dir = dirname(arg.c_str());
@@ -129,6 +130,7 @@ main(int argc, char *argv[])
if (src_name == NULL)
err(1, "basename");
+ std::string inst_src_path;
inst_src_path.append(src_dir);
inst_src_path.append("/inst/");
inst_src_path.append(src_name);