CCCC crashed on AMD64

Bug #376859 reported by Erwan Legrand
32
This bug affects 3 people
Affects Status Importance Assigned to Milestone
cccc (Ubuntu)
Fix Released
Medium
Colin Watson

Bug Description

Binary package hint: cccc

Here is a simple test case:

$ echo foobar | /usr/bin/cccc -
CCCC - a code counter for C and C++
===================================

A program to analyse C and C++ source code and report on
some simple software metrics
Version 3.pre84
Copyright Tim Littlefair, 1995, 1996, 1997, 1998, 1999, 2000
with contributions from Bill McLean, Herman Hueni, Lynn Wilson
Peter Bell, Thomas Hieber and Kenneth H. Cox.

The development of this program was heavily dependent on
the Purdue Compiler Construction Tool Set (PCCTS)
by Terence Parr, Will Cohen, Hank Dietz, Russel Quoung,
Tom Moog and others.

This software is provided with NO WARRANTY
Parsing
terminate called after throwing an instance of 'std::out_of_range'
  what(): basic_string::substr
Aborted (core dumped)

The package is cccc 3.pre84-2, Ubuntu Jaunty AMD64.

Revision history for this message
Erwan Legrand (epl) wrote :

Attached is a patch fixing the implicit integer cast this crash stems from.

Revision history for this message
Dave Gilbert (ubuntu-treblig) wrote :

Still broken in Raring cccc 3.1.4-5

Triaged: Reporter has a patch

Changed in cccc (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Dave Gilbert (ubuntu-treblig) wrote :

Looks like Colin pushed this report upstream 3 years ago; not been looked at though.

https://sourceforge.net/tracker/?func=detail&aid=2880497&group_id=7763&atid=107763

Revision history for this message
Thomas A. F. Thorne (tafthorne) wrote :

Make that 8 years ago.

Revision history for this message
Colin Watson (cjwatson) wrote :

Thanks for the patch, and sorry for the long delay. I've applied this in 1:3.1.4-11, which I've just uploaded to Debian, and will sync to Ubuntu shortly.

Changed in cccc (Ubuntu):
assignee: nobody → Colin Watson (cjwatson)
status: Triaged → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cccc - 1:3.1.4-11

---------------
cccc (1:3.1.4-11) unstable; urgency=medium

  * Policy version 4.2.1:
    - Use HTTPS form of copyright-format URL.
    - Set Rules-Requires-Root: no.
  * Fix implicit integer cast when parsing filenames (thanks, Erwan Legrand;
    LP: #376859).

 -- Colin Watson <email address hidden> Fri, 07 Sep 2018 10:35:41 +0100

Changed in cccc (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.