Write a context number into the BLR buffer. Check for possible overflow.
| 648 | |
| 649 | // Write a context number into the BLR buffer. Check for possible overflow. |
| 650 | void GEN_stuff_context(DsqlCompilerScratch* dsqlScratch, const dsql_ctx* context) |
| 651 | { |
| 652 | if (context->ctx_context > MAX_UCHAR) |
| 653 | ERRD_post(Arg::Gds(isc_too_many_contexts)); |
| 654 | |
| 655 | dsqlScratch->appendUChar(context->ctx_context); |
| 656 | |
| 657 | if (context->ctx_flags & CTX_recursive) |
| 658 | { |
| 659 | if (context->ctx_recursive > MAX_UCHAR) |
| 660 | ERRD_post(Arg::Gds(isc_too_many_contexts)); |
| 661 | |
| 662 | dsqlScratch->appendUChar(context->ctx_recursive); |
| 663 | } |
| 664 | } |
| 665 | |
| 666 | |
| 667 | // Write a context number into the BLR buffer. Check for possible overflow. |