Visitar URL original
Comparing cppchecksolutions:main...cppcheck-opensource:main · cppchecksolutions/cppcheck · GitHub
Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: cppchecksolutions/cppcheck
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: cppcheck-opensource/cppcheck
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 15 commits
  • 67 files changed
  • 5 contributors

Commits on Oct 26, 2026

  1. Fix #15124 FN bufferAccessOutOfBounds with wmemcpy() (cppcheck-openso…

    …urce#8951)
    
    Co-authored-by: chrchr-github <noreply@github.com>
    chrchr-github and web-flow authored Oct 26, 2026
    Configuration menu
    Copy the full SHA
    39574c6 View commit details
    Browse the repository at this point in the history
  2. strerror is now thread safe (cppcheck-opensource#8648)

    Before glibc 2.32, `strerror`() is not MT-Safe.
    (from man strerror on Ubuntu 26.04).
    
     glibc 2.32 was released on 2020-08-05 and glibc 2.43 on 2026-01-24
    (from https://sourceware.org/glibc/wiki/Glibc%20Timeline)
    
    This patch stops the `threadsafety.py` addon from warning about
    `strerror()`.
    
    `strerror` was used in `test/cli/other_test.py` to test
    `threadsafety.py` so we also patch that to use a different thread-unsafe
    function.
    andrew-aitchison authored Oct 26, 2026
    Configuration menu
    Copy the full SHA
    033ce38 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6fc12c3 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    2c5bf92 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    1516cd2 View commit details
    Browse the repository at this point in the history
  6. Remove valueFlowArrayBool() (redundancy with valueFlowImpossibleValue…

    …s()) (cppcheck-opensource#8905)
    
    Co-authored-by: chrchr-github <noreply@github.com>
    chrchr-github and web-flow authored Oct 26, 2026
    Configuration menu
    Copy the full SHA
    33c2c43 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    ef06677 View commit details
    Browse the repository at this point in the history

Commits on Oct 27, 2026

  1. Fix 15102: Make copy-constructible classes copyable (cppcheck-opensou…

    …rce#8705)
    
    Lots of copy constructible classes were using const and ref members which makes the classes non-copyable due to no longer supporting a copy-assignment. I replaced the ref members with a `RefThunk` class which is kind of like `std::reference_wrapper`, but it can access the member with `()` so its easier to access the members. It doesnt use `*` or `->` so it wont be confused for a possible null pointer.
    
    Now this PR doesnt replace all reference members, just for the classes that are copy-constructible. If we want to convert a class back to use reference or const members then we can delete the copy constructor and assignment. 
    
    Furthermore, I enabled the clang-tidy check `cppcoreguidelines-avoid-const-or-ref-data-members` to check for these cases in the future. Here are some references explaining why this is bad practice:
    
    * https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#rc-constref
    * https://lesleylai.info/en/const-and-reference-member-variables/
    * https://quuxplusone.github.io/blog/2022/01/23/dont-const-all-the-things/#data-members-never-const
    
    Beyond just being bad practice, this also has prevent me from doing certain things with the `ForwardAnalyzer` recently that might have improved it further such as joining or swaping a forked analyzer. I intentionally made these classes copyable for this reason(and were changed to non-copyable against [my feedback](cppcheck-opensource#4868 (comment)) as well). I understand that using references help prevent dereferencing a nullptr which is why I added a `RefThunk` class instead of using raw pointers like previously.
    pfultz2 authored Oct 27, 2026
    Configuration menu
    Copy the full SHA
    a573ac3 View commit details
    Browse the repository at this point in the history

Commits on Oct 28, 2026

  1. Configuration menu
    Copy the full SHA
    ffe7e9b View commit details
    Browse the repository at this point in the history
  2. Fix #15129: Improve matching performance for hash based suppressions (c…

    …ppcheck-opensource#8970)
    
    Makes it so that hash based suppressions are indexed by hash.
    Matching hash based suppressions is now O(1) (ignoring collisions)
    instead of O(n).
    For large code bases using baseline suppressions (which may be in the
    number of tens of thousands) this leads to a substantial speed up. We
    could probably speed up matching of other suppressions in the future as
    well, but I assume these are in general manually added and won't even
    get close to the same number as baseline suppressions. Also fixed a bug
    in ProcessExecutor that would cause new suppressions to be added
    unintentionally.
    ludviggunne authored Oct 28, 2026
    Configuration menu
    Copy the full SHA
    ebadd92 View commit details
    Browse the repository at this point in the history

Commits on Oct 29, 2026

  1. Configuration menu
    Copy the full SHA
    e8a1b2c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    3f3249f View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    5114436 View commit details
    Browse the repository at this point in the history

Commits on Oct 31, 2026

  1. Configuration menu
    Copy the full SHA
    422e3d0 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    bc89c29 View commit details
    Browse the repository at this point in the history
Loading