From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 48314 invoked by alias); 26 Jan 2017 22:21:04 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 48305 invoked by uid 89); 26 Jan 2017 22:21:03 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_05,FREEMAIL_FROM,KAM_COUK,RCVD_IN_DNSWL_NONE,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy=H*M:tiscali, H*i:4RmrKpX0W, H*f:sk:CAK-n8j, H*i:sk:OWchwhT X-HELO: smtp-out-6.tiscali.co.uk Received: from smtp-out-6.tiscali.co.uk (HELO smtp-out-6.tiscali.co.uk) (62.24.135.134) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 26 Jan 2017 22:21:02 +0000 Received: from [10.8.8.242] ([185.38.150.116]) by smtp.talktalk.net with SMTP id WsPVcAxe53OBfWsPac3MvE; Thu, 26 Jan 2017 22:20:59 +0000 Subject: Re: cppcheck 1.77 Segmentation fault (64-bit) To: cygwin@cygwin.com References: From: David Stacey Message-ID: <1461736e-51a3-3bb3-cbaf-90b6d41548a1@tiscali.co.uk> Date: Thu, 26 Jan 2017 22:21:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-CMAE-Envelope: MS4wfMft2SlbxnOLbwCsCtwJbl/IjTfslJkAPFkGK4a4nafagcGfz5XqVsFWl9nplR/z9n1OZantD2Q4ClXhtkwMECN68si68glU2Qexi2CT2lSn963tWlK1 v2jXCHBgLZBrd28hDPqj/vrjkBVQ98ybvtSwnxqKcWnfGZ1JENUoT7kH X-IsSubscribed: yes X-SW-Source: 2017-01/txt/msg00321.txt.bz2 On 26/01/2017 02:56, Jim Reisert AD1C wrote: > The latest version of cppcheck segment-faults. > > # cppcheck --enable=all -I include -I ../../library/include > -I/usr/include/libxml2 \ > --suppressions-list=dx4wupd.check \ > --suppress=missingIncludeSystem --quiet \ > --template={file}:{line}:{severity}:{message} > dx4wupd.cpp dx4wupdDlg.cpp I'm sorry, but I can't reproduce this. I tested cppcheck on some of my own code before uploading the package (I have a some deliberately dodgy code samples for this very purpose) and it worked fine. I also run cppcheck's own testsuite as part of the build, and all of those tests passed. Are you able to run really simple cppcheck commands, such as 'cppcheck --version' or 'cppcheck --help'? If those work, what happens if you simplify the command line somewhat - say just scan one file, or omit the suppression switches, or omit the templates / include paths? Can you isolate one command line switch that's causing the crash? If cppcheck still seg faults, can you send me a sample of code that exhibits the problem? If you don't want to post the source code to a public mailing list, you can e-mail a sample to me privately. Don't include your entire build tree, but try to cut it down to a small sample that still exhibits the problem. > Stack trace: > Frame Function Args > 000FFFFBAA0 001004E27F3 (00000000000, 001801FC280, 00000000002, 00100509D10) > 000FFFFBDB0 0010040229F (0030000000D, 000FFFFCC00, 000FFFFCA90, 000FFFFC9C0) > 000FFFFCC00 00100405C31 (003E6FCF578, 003E6FCF578, 00000000008, 001005CFBE0) > 000FFFFCC00 00100408ADC (001801441C9, 003E6F79950, 001802E5880, 001005CF790) > 000FFFFCCC0 0010059E5FE (00180188C7A, 0018023BE00, 00180053801, 0000000002F) > 000FFFFCCC0 00180047902 (00000000000, 00000000000, 00000000000, 00000000000) > 00000000000 00180045693 (00000000000, 00000000000, 00000000000, 00000000000) > 000FFFFFFF0 00180045744 (00000000000, 00000000000, 00000000000, 00000000000) > End of stack trace Thanks for including that, but sadly it's not as helpful as it might be. The stack trace shows the code going bang in the constructor of a std::basic_istream, but that doesn't really make sense (to me at least) in the context of the parent frame(s). It could be that there's some inlined code or a compiler generated function confusing me. A couple of frames in and we're into cppcheck code. It's going over just after parsing the command line arguments - so I don't think it's even started looking at your code yet. With that in mind, I copied and pasted the exact same command you gave, and whilst it gave an error message (as I don't have your source files) it didn't crash. So send me a sample of code that reproduces the problem, and I'll take another look. Dave. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple