Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VeriFast can’t correctly handle named fractions of char arrays that are part of a struct. #12

Open
amintimany opened this issue Apr 11, 2016 · 0 comments

Comments

@amintimany
Copy link
Contributor

VeriFast can’t correctly handle named fractions (dummy fractions don’t trigger this error) of char arrays that are part of a struct.

The following code:

struct strc {
 char chrs[3];//interestingly 1 does not trigger the error
};

void error(struct strc *x)
    //@ requires [?f]chars(x->chrs, 3, _);
          // it seems that the length (3 here) must be greater than or equal to
          // the length of the array in the struct to trigger the error.
    //@ ensures true;
{
free(x);
}

causes VeriFast to crash (exception with Redux prover and seg-fault with z3).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant