Searched refs:trap (Results 1 – 25 of 240) sorted by relevance
12345678910
3 traps=$(${SH} -c 'trap "echo bad" 0; trap - 0; trap')5 traps=$(${SH} -c 'trap "echo bad" 0; trap "" 0; trap')6 expected_traps=$(${SH} -c 'trap "" EXIT; trap')8 traps=$(${SH} -c 'trap "echo bad" 0; trap 0; trap')10 traps=$(${SH} -c 'trap "echo bad" 0; trap -- 0; trap')12 traps=$(${SH} -c 'trap "echo bad" 0 1 2; trap - 0 1 2; trap')14 traps=$(${SH} -c 'trap "echo bad" 0 1 2; trap "" 0 1 2; trap')15 expected_traps=$(${SH} -c 'trap "" EXIT HUP INT; trap')17 traps=$(${SH} -c 'trap "echo bad" 0 1 2; trap 0 1 2; trap')19 traps=$(${SH} -c 'trap "echo bad" 0 1 2; trap -- 0 1 2; trap')
4 trap - USR15 initial=$(trap)6 trap -- -l USR17 added=$(trap)9 trap - USR110 second=$(trap)13 added2=$(trap)14 added3=$(trap --)17 trap -- - USR118 third=$(trap)
4 trap '' garbage && exit 35 trap - garbage && exit 36 trap true garbage && exit 37 trap '' 99999 && exit 38 trap - 99999 && exit 39 trap true 99999 && exit 3
2 # This is really a test for outqstr(), which is readily accessible via trap.7 trap -- "$teststring" USR18 traps=$(trap)13 # in the normative description of the trap builtin shows the15 echo '$(trap) is broken'18 trap - USR120 traps2=$(trap)
3 test "$(trap 'echo trapped' EXIT; :)" = trapped || exit 15 test "$(trap 'echo trapped' EXIT; /usr/bin/true)" = trapped || exit 17 result=$(${SH} -c 'trap "echo trapped" EXIT; /usr/bin/false')11 result=$(${SH} -c 'trap "echo trapped" EXIT; exec /usr/bin/false')16 trap 'result=$((result+1))' INT
3 # Check that the return statement will not break the EXIT trap, ie. all4 # trap commands are executed before the script exits.6 test "$(trap 'printf trap; echo ped' EXIT; f() { return; }; f)" = trapped || exit 1
4 # further trap names in the same trap command after an invalid one.6 test -n "$(trap true garbage TERM 2>/dev/null || trap)" || exit 3
3 # Check that the return statement will not break the USR1 trap, ie. all4 # trap commands are executed before the script resumes.6 result=$(${SH} -c 'trap "printf trap; echo ped" USR1; f() { return $(kill -USR1 $$); }; f')
4 trap 'rm -rf $T' 013 trap 'trap "" PIPE; echo trapped >&3 2>/dev/null' PIPE
3 test "$(trap 'printf trap; echo ped' EXIT; f() { :; }; f)" = trapped || exit 1
3 # exit without arguments differs from exit $? in an EXIT trap.5 trap 'false; exit' 0
3 # exit without arguments is the same as exit $? outside a trap.5 trap 'true; true' 0
3 # exit with an argument should overwrite the exit status in an EXIT trap.5 trap 'true; exit $?' 0
4 trap 'rm -rf $T' 08 trap trapped=1 QUIT
5 trap 'trap "echo bad" USR1
205 if (trap[signo]) in trapcmd()206 ckfree(trap[signo]); in trapcmd()207 trap[signo] = action; in trapcmd()224 for (tp = trap ; tp <= &trap[NSIG - 1] ; tp++) { in clear_traps()229 if (tp != &trap[0]) in clear_traps()230 setsignal(tp - trap); in clear_traps()245 for (tp = trap ; tp <= &trap[NSIG - 1] ; tp++) { in have_traps()369 return (trap[SIGCHLD] != NULL && *trap[SIGCHLD] != '\0'); in issigchldtrapped()392 if (trap[signo] != NULL && trap[signo][0] != '\0' && in onsig()419 if (trap[i]) { in dotrap()[all …]
12 check $LINENO "$(trap "echo bye" EXIT; : >/dev/null)" bye13 check $LINENO "$(trap "echo bye" EXIT; { :; } >/dev/null)" bye14 check $LINENO "$(trap "echo bye" EXIT; (:) >/dev/null)" bye15 check $LINENO "$(trap "echo bye" EXIT; (: >/dev/null))" bye16 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; : >/dev/null')" bye17 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; { :; } >/dev/null')" bye18 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; (:) >/dev/null')" bye19 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; (: >/dev/null)')" bye
12 check $LINENO "$(trap "echo bye" EXIT; f() { :; }; f >/dev/null)" bye13 check $LINENO "$(trap "echo bye" EXIT; f() { :; }; { f; } >/dev/null)" bye14 check $LINENO "$(trap "echo bye" EXIT; f() { :; }; (f) >/dev/null)" bye15 check $LINENO "$(trap "echo bye" EXIT; f() { :; }; (f >/dev/null))" bye16 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; f() { :; }; f >/dev/null')" bye17 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; f() { :; }; { f; } >/dev/null')" bye18 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; f() { :; }; (f) >/dev/null')" bye19 check $LINENO "$(${SH} -c 'trap "echo bye" EXIT; f() { :; }; (f >/dev/null)')" bye
4 trap 'rm -rf $T' 07 # Use a trap, not the default action, since the shell may catch SIGINT and9 { trap 'exit 5' TERM; read dummy <fifo1; exit 4; } &
4 trap 'rm -rf $T' 07 # Use a trap, not the default action, since the shell may catch SIGINT and9 { set -C; trap 'exit 5' TERM; read dummy <fifo1; exit 4; } &
4 trap 'rm -rf $T' 07 { trap - INT; : >fifo1; sleep 5 & wait; exit 4; } &
2631 // .trap variants2635 "llvm.nvvm.suld.1d.i8.trap">;2639 "llvm.nvvm.suld.1d.i16.trap">;2643 "llvm.nvvm.suld.1d.i32.trap">;2647 "llvm.nvvm.suld.1d.i64.trap">;2725 "llvm.nvvm.suld.2d.i8.trap">;2729 "llvm.nvvm.suld.2d.i16.trap">;2733 "llvm.nvvm.suld.2d.i32.trap">;2737 "llvm.nvvm.suld.2d.i64.trap">;2815 "llvm.nvvm.suld.3d.i8.trap">;[all …]
8 6 Trace/BPT trap10 8 IOT trap13 11 EMT trap