diff options
| author | dam <dam@gudinoff> | 2023-03-27 17:54:24 +0100 |
|---|---|---|
| committer | dam <dam@gudinoff> | 2023-03-27 17:54:24 +0100 |
| commit | e4bae939aea065fa5745e224fc0eb12d5136d1c4 (patch) | |
| tree | 89106a19cee65e747a86593e14e0324bea5b7599 | |
| parent | fdb58e513aeddb566c9de9f67d59cf5f25e8ead7 (diff) | |
| download | task-time-tracker-e4bae939aea065fa5745e224fc0eb12d5136d1c4.tar.zst task-time-tracker-e4bae939aea065fa5745e224fc0eb12d5136d1c4.zip | |
Fixing memory leaks.
| -rw-r--r-- | ttt.jai | 19 |
1 files changed, 10 insertions, 9 deletions
@@ -1213,15 +1213,16 @@ void *mem_alloc(size_t mem_size, const char *error_tag) { */ free_memory :: () { print(">> FREE <<\n"); - /* TODO - reset_database(&database); - reset_database(&archive); - free(string_buffer); string_buffer = NULL; - free(app_directory); app_directory = NULL; - free(db_file_path); db_file_path = NULL; - free(ar_file_path); ar_file_path = NULL; - */ + // TODO + //reset_database(&database); + //reset_database(&archive); + + //free(string_buffer); string_buffer = NULL; + free(app_directory); + free(db_file_path); + free(ar_file_path); + //reset_temporary_storage(); } /* @@ -1304,7 +1305,7 @@ main :: () { home_dir = "."; } - home_path, success_path := get_absolute_path(home_dir); // Returns temporary memory. + home_path, success_path := get_absolute_path(home_dir); // Returns temporary memory. TODO LEAK if success_path == false { print_error("Failed to find home directory '%'.", home_dir); return; |
