From cf99abb852536867169168d2c7fabf158099dfd9 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Thu, 23 Sep 2021 13:38:20 -0700 Subject: WIP implementation of setjmp/longjmp recovery --- bp.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'bp.c') diff --git a/bp.c b/bp.c index 08cde5c..078afff 100644 --- a/bp.c +++ b/bp.c @@ -463,6 +463,8 @@ int main(int argc, char *argv[]) file_t *arg_file = spoof_file(&loaded_files, "", flag, -1); pat_t *p = bp_pattern(arg_file, arg_file->start); if (!p) file_err(arg_file, arg_file->start, arg_file->end, "Failed to compile this part of the argument"); + if (p->type == BP_ERROR) + file_err(arg_file, p->args.error.start, p->args.error.end, p->args.error.msg); if (after_spaces(p->end, true) < arg_file->end) file_err(arg_file, p->end, arg_file->end, "Failed to compile this part of the argument"); pattern = chain_together(arg_file, pattern, p); } else if (FLAG("-w") || FLAG("--word")) { -- cgit v1.2.3