bugGNU Kart - Bugs: bug #47048, Command line args causing segfault


bug #47048: Command line args causing segfault

Submitted by:  David Benoit <benoid64>
Submitted on:  Tue 02 Feb 2016 10:37:13 PM UTC  
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: sebastien diaz <sebdiaz>
Open/Closed: Open

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Tue 02 Feb 2016 10:37:13 PM UTC, original submission:
  • Expected result: program handles invalid parameters
  • Actual Result: program crashes with segfault

*Steps to reproduce:
1) Run program with a flag that takes another argument, but
do not supply the argument. ex:
./gnukart -w
./gnukart -h
2) Program segfaults

  • Steps to fix:

1) Update main.c function parse_args()
- all conditionals currently attempt to check for
invalid num args by evaluating the statement
if (argc < i + 1)
- they should check to see if (argc <= i + 1)
2) Segfault error is fixed

David Benoit <benoid64>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by benoid64 (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 23 Jun 2017 07:55:37 PM UTCsebdiazStatusNone=>Fixed
      Assigned toNone=>sebdiaz

    Back to the top

    Powered by Savane 3.1-cleanup1