udev: save stats of all udev rules file

The mtime of directory is not updated when an existing rule file is
changed. Hence, paths_check_timestamp() is not reliable.
This commit is contained in:
Yu Watanabe
2022-07-23 15:05:22 +09:00
parent 3f4dfd9d87
commit acfbd71ccc
5 changed files with 36 additions and 13 deletions
+1 -1
View File
@@ -445,7 +445,7 @@ int config_parse(
return 1;
}
static int hashmap_put_stats_by_path(Hashmap **stats_by_path, const char *path, const struct stat *st) {
int hashmap_put_stats_by_path(Hashmap **stats_by_path, const char *path, const struct stat *st) {
_cleanup_free_ struct stat *st_copy = NULL;
_cleanup_free_ char *path_copy = NULL;
int r;
+1
View File
@@ -122,6 +122,7 @@ int config_get_stats_by_path(
bool check_dropins,
Hashmap **ret);
int hashmap_put_stats_by_path(Hashmap **stats_by_path, const char *path, const struct stat *st);
bool stats_by_path_equal(Hashmap *a, Hashmap *b);
typedef struct ConfigSection {