From: Ioan-Adrian Ratiu Date: Sat, 10 Dec 2016 19:54:07 +0000 (+0200) Subject: notmuch-config: replace config reading function X-Git-Tag: 0.24_rc0~57 X-Git-Url: https://git.cworth.org/git?a=commitdiff_plain;h=f2a038825b73d4b9fa6cfd3ecbe661f1e6a49840;hp=f2a038825b73d4b9fa6cfd3ecbe661f1e6a49840;p=notmuch notmuch-config: replace config reading function Config files are currently read using glib's g_key_file_load_from_file function which is very inconvenient because it's limited by design to read only from "regular data files" in a filesystem. Because of this limitation notmuch can't read configs from pipes, fifos, sockets, stdin, etc. Not even "notmuch --config=/dev/stdin" works: Error reading configuration file /dev/stdin: Not a regular file So replace g_key_file_load_from_file with g_key_file_load_from_data which gives us much more freedom to read configs from multiple sources. This also helps the more security sensitive users: If someone has private information in the config file, it can be encrypted on disk, then decrypted in RAM and passed through a pipe directly to notmuch without the use of intermediate plain text files. Signed-off-by: Ioan-Adrian Ratiu ---