The post-condition on the functions is that the buffer is not full.
This post-conditon is used as pre-condition of the push_back function.
When a copy, fill, of transform function exactly fit in the buffer this
post-condition was validated.
Details
Details
- Reviewers
ldionne - Group Reviewers
Restricted Project - Commits
- rG7583c73bc4fa: [libc++][format] Fixes an off by one error.
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
This was reported in the security bug tracker at https://bugs.chromium.org/p/llvm/issues/detail?id=48 . That issue was not accessible at first, but I have removed the security restriction now.
Comment Actions
We (a small team inside Salesforce) found this in one of our production builds by accident / sheer luck. We are using -fexperimental-library already, because we recompile the world anyway (and don't need ABI stability) and are happy to rewrite our code in case breaking API changes are applied to libc++ or the C++ standard.
I agree that fuzzing might be a good idea for std::format to find this type of issues in a more structured way