diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2019-11-13 17:36:46 +0100 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2019-11-13 22:04:51 +0100 |
commit | ed4ad4889723a9acdf75ed86f10cee0024bbbcbc (patch) | |
tree | a9cb824bcefb634a8d913b6bd24912eb964ebb3b /src/shared/fstab-util.h | |
parent | 32c6237a7c2e697d2fc4f3403319db16858fb8e3 (diff) | |
download | systemd-ed4ad4889723a9acdf75ed86f10cee0024bbbcbc.tar.gz systemd-ed4ad4889723a9acdf75ed86f10cee0024bbbcbc.tar.bz2 systemd-ed4ad4889723a9acdf75ed86f10cee0024bbbcbc.zip |
Allow overriding /etc/fstab with $SYSTEMD_FSTAB
Diffstat (limited to 'src/shared/fstab-util.h')
-rw-r--r-- | src/shared/fstab-util.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/shared/fstab-util.h b/src/shared/fstab-util.h index 0862256511..f575ed0bb2 100644 --- a/src/shared/fstab-util.h +++ b/src/shared/fstab-util.h @@ -31,3 +31,7 @@ static inline bool fstab_test_yes_no_option(const char *opts, const char *yes_no } char *fstab_node_to_udev_node(const char *p); + +static inline const char* fstab_path(void) { + return secure_getenv("SYSTEMD_FSTAB") ?: "/etc/fstab"; +} |