Skip to content

Possible out-of-bounds access in bfset.h #428

Description

@cgbriggs99

It seems that there may be an error in bfset.h. Specifically here.

for (unsigned int xyz = 0; xyz < 3; ++xyz) Diff.dec(xyz, B.d(xyz));

When NDIM is 1, this will try to read past the end of the array, resulting in undefined behavior. Perhaps the 3 is supposed to be NDIM?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions