bc: fix a thinko: dc uses [] string delimiters, bot bc!

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
1_30_stable
Denys Vlasenko 2018-12-13 17:46:26 +01:00
parent 766f67250f
commit 335b4efd2f
1 changed files with 2 additions and 2 deletions

View File

@ -7076,9 +7076,9 @@ static BC_STATUS zbc_vm_stdin(void)
char c = *string;
if (string != buf.v && string[-1] != '\\') {
// checking applet type is cheaper than accessing sbgn/send
if (IS_DC) // dc: sbgn = send = '"'
if (IS_BC) // bc: sbgn = send = '"'
str ^= (c == '"');
else { // bc: sbgn = '[', send = ']'
else { // dc: sbgn = '[', send = ']'
if (c == ']')
str -= 1;
else if (c == '[')