Apply errexit & errreturn to for loop assignment error (#46052)
@@ -23,6 +23,8 @@ | ||
23 | 23 | = The "array" built-in is now completely ignored in the POSIXly- |
24 | 24 | correct mode. The built-in, formerly a regular built-in, is now |
25 | 25 | categorized as an "extension" built-in. |
26 | + * The errexit and errreturn options now work for assignment error | |
27 | + in a for loop. | |
26 | 28 | * The ">" redirection with the noclobber option no longer hangs |
27 | 29 | when the operand names a symbolic link to a non-existing file. |
28 | 30 |
@@ -1311,6 +1311,7 @@ | ||
1311 | 1311 | SCOPE_LOCAL : SCOPE_GLOBAL, |
1312 | 1312 | false)) { |
1313 | 1313 | laststatus = Exit_ASSGNERR; |
1314 | + apply_errexit_errreturn(NULL); | |
1314 | 1315 | if (!is_interactive_now) |
1315 | 1316 | finally_exit = true; |
1316 | 1317 | goto done; |