From 6a5412e0b15fc68844ffd16f029e3f002b9cfb43 Mon Sep 17 00:00:00 2001 From: Andrew Cady Date: Sun, 1 May 2016 01:33:25 -0400 Subject: remove unused files --- src/initrd/halt.montecarlo | 39 --------------------------------------- 1 file changed, 39 deletions(-) delete mode 100755 src/initrd/halt.montecarlo (limited to 'src/initrd/halt.montecarlo') diff --git a/src/initrd/halt.montecarlo b/src/initrd/halt.montecarlo deleted file mode 100755 index 67dac17..0000000 --- a/src/initrd/halt.montecarlo +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/bash - -cmd=${0##*/} -dashf= -for arg in "$@"; do - case "$arg" in -*f*) dashf=1 ;; esac - case "$arg" in -*p*) [ "$cmd" = halt ] && cmd=poweroff ;; esac -done - -[ "$dashf" ] || exec -a "$0" /sbin/halt.distrib "$@" - -read pids < /run/sendsigs.omit.d/samizdat -for p in $pids; do - if [ -e /proc/$p/root -a ! /proc/$p/root -ef / ]; then - initramfs=/proc/$p/root - break - fi -done - -panic() -{ - set -x - sync - exec -a "$0" /sbin/halt.distrib "$@" -} - -[ "$initramfs" ] || panic - -cp /sbin/init $initramfs/telinit - -# Apparently, linux does not allow a direct bind mount of a file on -# the initramfs. Therefore, copy the file from the initramfs and bind -# mount the copy. - -mount -o remount,exec /run -cp $initramfs/lib/samizdat/init.shutdown /run/ && mount --bind /run/init.shutdown /sbin/init || panic - -echo $cmd -f > $initramfs/halt -$initramfs/telinit u -- cgit v1.2.3