1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-07-26 16:45:12 -04:00

[terminal] Make a copy of filename for hash

This commit is contained in:
Witold Filipczyk 2023-11-26 19:00:04 +01:00
parent 49285684ea
commit db99981ec5

View File

@ -97,7 +97,11 @@ save_temporary_filename(const char *filename)
}
if (temporary_files) {
add_hash_item(temporary_files, filename, strlen(filename), NULL);
char *copy = stracpy(filename);
if (copy) {
add_hash_item(temporary_files, copy, strlen(copy), NULL);
}
}
}