File tree 1 file changed +4
-2
lines changed
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -652,7 +652,7 @@ report_json_context(JsonLexContext *lex)
652
652
context_end = lex -> token_terminator ;
653
653
654
654
/* Advance until we are close enough to context_end */
655
- while (context_end - context_start >= 50 && context_start < context_end )
655
+ while (context_end - context_start >= 50 )
656
656
{
657
657
/* Advance to next multibyte character */
658
658
if (IS_HIGHBIT_SET (* context_start ))
@@ -680,7 +680,9 @@ report_json_context(JsonLexContext *lex)
680
680
* suffixing "..." if not ending at end of line.
681
681
*/
682
682
prefix = (context_start > line_start ) ? "..." : "" ;
683
- suffix = (lex -> token_type != JSON_TOKEN_END && context_end - lex -> input < lex -> input_length && * context_end != '\n' && * context_end != '\r' ) ? "..." : "" ;
683
+ suffix = (lex -> token_type != JSON_TOKEN_END &&
684
+ context_end - lex -> input < lex -> input_length &&
685
+ * context_end != '\n' && * context_end != '\r' ) ? "..." : "" ;
684
686
685
687
return errcontext ("JSON data, line %d: %s%s%s" ,
686
688
lex -> line_number , prefix , ctxt , suffix );
You can’t perform that action at this time.
0 commit comments