~harrison-rt/sapidlib/fluffos

« back to all changes in this revision

Viewing changes to src/vm/internal/base/interpret.cc

  • Committer: Yucong Sun
  • Date: 2021-10-31 00:29:17 UTC
  • Revision ID: git-v1:3fe705f8a65268569007e8480c0a9a3dfa3c1773
Fix crash in null REF variable

Show diffs side-by-side

added added

removed removed

Lines of Context:
2029
2029
        svalue_t *s = fp + EXTRACT_UCHAR(pc++);
2030
2030
        svalue_t *reflval = nullptr;
2031
2031
 
 
2032
        if (s->type != T_REF) {
 
2033
          error("Reference is invalid.\n");
 
2034
        }
 
2035
 
2032
2036
        {
2033
2037
          reflval = s->u.ref->lvalue;
2034
2038
          if (!reflval) {