Make use of "ensure_directory" function (#1765)

This commit is contained in:
Mark Thompson
2024-01-13 07:57:32 +01:00
committed by GitHub
parent 409242507c
commit 58307aee9c
8 changed files with 10 additions and 24 deletions
+1 -1
View File
@@ -275,7 +275,7 @@ bool memory_dump(uint32_t* addr_start, uint32_t num_words, bool stack_flag) {
int n{0};
bool data_found{false};
make_new_directory(debug_dir);
ensure_directory(debug_dir);
filename = next_filename_matching_pattern(debug_dir + "/" + (stack_flag ? "STACK" : "MEMORY") + "_DUMP_????.TXT");
error = filename.empty();
if (!error)