You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-full-overlay/app-shells/bash/files/bash-3.0-volatile-command.p...

17 lines
442 B

Ripped from Debian
# DP: current_command must be declared volatile to prevent assignments from
# being optimized away as dead code. In reality, the use of setjmp/longjmp
# makes it not dead code at all.
--- a/eval.c
+++ b/eval.c
@@ -63,7 +63,7 @@
reader_loop ()
{
int our_indirection_level;
- COMMAND *current_command = (COMMAND *)NULL;
+ COMMAND * volatile current_command = (COMMAND *)NULL;
USE_VAR(current_command);