bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

executes statement after "exit"


From: Frank Heckenbach
Subject: executes statement after "exit"
Date: Fri, 15 Apr 2022 18:57:07 +0200

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -g -O2 -fstack-protector-strong -Wformat 
-Werror=format-security -Wall 
uname output: Linux mars 5.10.0-12-amd64 #1 SMP Debian 5.10.103-1 (2022-03-07) 
x86_64 GNU/Linux
Machine Type: x86_64-pc-linux-gnu

Bash Version: 5.1
Patch Level: 16
Release Status: release

Description:

bash executes statement after "exit".

Happens with or without "set -e".

Doesn't happen with newline instead of ";".

Similar to https://bugs.debian.org/819327, but perhaps not the same
(as that one also happens with newline).

#!/bin/bash
: $((08 + 0)); exit
echo "Should not get here."

But I guess that's also prescribed by POSIX, right?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]