params: cleanup old params that aren't defined (#28017)

* delete files that are not defined in the keys

* assert after create file

* remove util::remove_files_in_dir

* cleanup

* fix up test

---------

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 10a1b8b7b172420047fab5caa84829dd510e1e38
This commit is contained in:
Dean Lee
2023-05-05 02:21:41 +08:00
committed by GitHub
parent 09fe521cfe
commit 3ff040d52c
5 changed files with 20 additions and 40 deletions

View File

@@ -81,7 +81,6 @@ std::string dir_name(std::string const& path);
// **** file fhelpers *****
std::string read_file(const std::string& fn);
std::map<std::string, std::string> read_files_in_dir(const std::string& path);
void remove_files_in_dir(const std::string& path);
int write_file(const char* path, const void* data, size_t size, int flags = O_WRONLY, mode_t mode = 0664);
FILE* safe_fopen(const char* filename, const char* mode);