bugGNU Gengetopt - Bugs: bug #41369, SIGABRT and core dump for...


bug #41369: SIGABRT and core dump for nonexistent --output-dir

Submitted by:  Nick Markham <nmarkham>
Submitted on:  Mon Jan 27 20:39:52 2014  
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: None
Privacy: PublicAssigned to: None
Originator Name: Open/Closed: Open

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

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


Thu Feb 20 21:13:52 2014, comment #3:

Attached a patch to the bug. (I hope that's the right way to submit one?)

Nick Markham <nmarkham>
Fri Feb 14 17:46:48 2014, comment #2:

mh... probably you're right, and that might be code written a few time ago; I'll try to address this issue, but I can't promise I can do right now. Patches are more than welcome :)

Lorenzo Bettini <bettini>
Project Administrator
Mon Jan 27 21:04:40 2014, comment #1:

After a brief investigation, I see that this seems to be intentional: fileutils.cpp:52 calls abort() directly. I'm wondering if there's a reason for this? Personally, I would've expected a non-zero return value and a message on standard error, but not a signal nor core dump for something like this.

Nick Markham <nmarkham>
Mon Jan 27 20:39:52 2014, original submission:

Looks like a bit of additional error checking is needed:

$ gengetopt --output-dir=does-not-exist </dev/null
Error creating does-not-exist/cmdline.h
Aborted (core dumped)

This also applies, unsurprisingly, to --src-output-dir and --header-output-dir. I also verified that an unwriteable directory produces the same issue

Nick Markham <nmarkham>


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

Attach File(s):

Attached Files
file #30619:  gengetopt-bug-41369.patch added by nmarkham (428B - application/octet-stream - Patch containing suggested fix)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by bettini (Posted a comment)
  • -unavailable- added by nmarkham (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):



    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu Feb 20 21:12:40 2014nmarkhamAttached File-=>Added gengetopt-bug-41369.patch, #30619

    Back to the top

    Powered by Savane 3.1-cleanup1