diff options
Diffstat (limited to 'gcc/gcov.c')
-rw-r--r-- | gcc/gcov.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1377,7 +1377,9 @@ generate_results (const char *file_name) json::object *root = new json::object (); root->set ("format_version", new json::string ("1")); root->set ("gcc_version", new json::string (version_string)); - root->set ("current_working_directory", new json::string (bbg_cwd)); + + if (bbg_cwd != NULL) + root->set ("current_working_directory", new json::string (bbg_cwd)); json::array *json_files = new json::array (); root->set ("files", json_files); |