From f461a28da70320473c7466bcdc34fa601da0877b Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Tue, 21 Mar 2023 21:17:22 +0100 Subject: chase-symlinks: Rename chase_symlinks() to chase() Chasing symlinks is a core function that's used in a lot of places so it deservers a less verbose names so let's rename it to chase() and chaseat(). We also slightly change the pattern used for the chaseat() helpers so we get chase_and_openat() and similar. --- src/fstab-generator/fstab-generator.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/fstab-generator') diff --git a/src/fstab-generator/fstab-generator.c b/src/fstab-generator/fstab-generator.c index 28cd5f05f1..69effacaa2 100644 --- a/src/fstab-generator/fstab-generator.c +++ b/src/fstab-generator/fstab-generator.c @@ -7,7 +7,7 @@ #include "alloc-util.h" #include "bus-error.h" #include "bus-locator.h" -#include "chase-symlinks.h" +#include "chase.h" #include "efi-loader.h" #include "env-util.h" #include "fd-util.h" @@ -723,12 +723,11 @@ static int parse_fstab(bool initrd) { * where a symlink refers to another mount target; this works assuming the sub-mountpoint * target is the final directory. * - * FIXME: when chase_symlinks() learns to chase non-existent paths, use this here and + * FIXME: when chase() learns to chase non-existent paths, use this here and * drop the prefixing with /sysroot on error below. */ - k = chase_symlinks(where, initrd ? "/sysroot" : NULL, - CHASE_PREFIX_ROOT | CHASE_NONEXISTENT, - &canonical_where, NULL); + k = chase(where, initrd ? "/sysroot" : NULL, CHASE_PREFIX_ROOT | CHASE_NONEXISTENT, + &canonical_where, NULL); if (k < 0) { /* If we can't canonicalize, continue as if it wasn't a symlink */ log_debug_errno(k, "Failed to read symlink target for %s, using as-is: %m", where); -- cgit v1.2.1