Files
domenico 27c9d80f51
Some checks failed
Build Kernel / Build all affected Kernels (push) Has been cancelled
Build all core packages / Build all core packages for selected target (push) Has been cancelled
Build and Push prebuilt tools container / Build and Push all prebuilt containers (push) Has been cancelled
Build Toolchains / Build Toolchains for each target (push) Has been cancelled
Build host tools / Build host tools for linux and macos based systems (push) Has been cancelled
Coverity scan build / Coverity x86/64 build (push) Has been cancelled
Initial commit
2025-06-24 12:51:15 +02:00

39 lines
784 B
Bash

#!/bin/sh
# Copyright 2010 Vertical Communications
# Copyright 2012 OpenWrt.org
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
fsck_e2fsck() {
set -o pipefail
e2fsck -p "$device" 2>&1 | logger -t "fstab: e2fsck ($device)"
local status="$?"
set +o pipefail
case "$status" in
0|1) ;; #success
2) reboot;;
4) echo "e2fsck ($device): Warning! Uncorrected errors."| logger -t fstab
return 1
;;
*) echo "e2fsck ($device): Error $status. Check not complete."| logger -t fstab;;
esac
return 0
}
fsck_ext2() {
fsck_e2fsck "$@"
}
fsck_ext3() {
fsck_e2fsck "$@"
}
fsck_ext4() {
fsck_e2fsck "$@"
}
append libmount_known_fsck "ext2"
append libmount_known_fsck "ext3"
append libmount_known_fsck "ext4"