diff options
author | Colin Walters <walters@verbum.org> | 2016-10-11 11:28:39 -0400 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2016-10-11 11:28:39 -0400 |
commit | 7bf494eb0838f328c1247f60deb637552c1fb170 (patch) | |
tree | 6088410f99c0824e1a12683929e311142a8e7a68 | |
parent | 4ab2a8d5f1f6efbd4105f3366c5ff10137ba0bc0 (diff) | |
download | gnutls-7bf494eb0838f328c1247f60deb637552c1fb170.tar.gz |
priorities: Do read crypto policy files with mtime of zero
In a default Fedora Atomic Host installation,
`/etc/crypto-policies/backends/gnutls.config` is a symlink to the
default in `/usr/share/`. On an OSTree-managed system, files in
`/usr` have an mtime of zero (to help deduplication).
The simple fix here is to still try to read the first time, even if
the file has an mtime of zero.
-rw-r--r-- | lib/priority.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/priority.c b/lib/priority.c index 0fa38f9367..880fa584f0 100644 --- a/lib/priority.c +++ b/lib/priority.c @@ -945,7 +945,8 @@ static void _gnutls_update_system_priorities(void) return; } - if (sb.st_mtime == system_priority_last_mod) { + if (system_priority_buf != NULL && + sb.st_mtime == system_priority_last_mod) { _gnutls_debug_log("system priority %s has not changed\n", system_priority_file); return; |