Menu

-j option crashing with segmentation violation at/near end of processing

T Tanner
2022-07-05
2022-07-07
  • T Tanner

    T Tanner - 2022-07-05

    I have a directory with 9 files in it. I can run cppcheck --force --inline-suppr -I . that/ and it works fine. If I add -j4 to that. boom. segmentation violation after about 6 files of the 9.

    -j 2 and -j 3 work fine Higher -js also work but can process more files

    I tried a different directory in the same project (with 34 files), and -j 4 succeeded, although -j 6 failed with segmentation violation)

    I'm not really sure how to usefully track this down further.

     

    Last edit: T Tanner 2022-07-05
  • Daniel Marjamäki

    Do you use linux or windows?

    Could you compile cppcheck and run it in a debugger? That is easy if you have g++ or visual studio.

     
  • T Tanner

    T Tanner - 2022-07-06

    I'm running on windows with mingw64. I guess I could try that - i can certainly try gdb-ing as is

     
  • T Tanner

    T Tanner - 2022-07-06

    gdb comes up with a lot of "warning: Invalid parameter passed to c runtime function" messages
    and of course it doesn't crash with -j4 and i had to try with -j5. that crashes but there are no symbols

     
  • CHR

    CHR - 2022-07-07

    This may or may not be an instance of this problem: https://github.com/danmar/cppcheck/pull/4229
    Maybe you could apply that patch and see if it's fixed?

     
  • T Tanner

    T Tanner - 2022-07-07

    i could try but i'd be building on mingw64 so it might take a while

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.