bugXnee - Bugs: bug #14629, Core dump from gnee

 
 

bug #14629: Core dump from gnee

Submitter:  Peter Fales <psfales>
Submitted:  Fri 23 Sep 2005 10:04:18 PM UTC
   
 
Category:  gnee Severity:  3 - Normal
Item Group:  Error report Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 09 Dec 2005 09:19:54 AM UTC, comment #1: 

Fixed in (coming) 2.02

Henrik Sandklef <hesa>
Group administrator
Fri 23 Sep 2005 10:04:18 PM UTC, original submission:  

Near the beginning of main.c in cnee, there is code to set the program name:

  /* Set the program name */
  xnee_set_program_name (xd, XNEE_CLI);

gnee does not have any similar logic, and as a result the program name is not set.   When a file "save" operation is invoked, this results in a null pointer being passed to printf.  On linux with glibc, this simply causes the line in the output file to be:

ProjectCreationProgram:         (null)

But on other platforms (such as solaris) with less friendly implmentations of printf, this causes a core dump.

I used the following patch to fix it:

diff -ur Xnee-2.01/gnee/src/main.c Xnee-2.01.new/gnee/src/main.c
--- Xnee-2.01/gnee/src/main.c   2005-09-12 08:32:02.000000000 -0500
+++ Xnee-2.01.new/gnee/src/main.c       2005-09-23 15:56:16.000000000 -0500
@@ -157,6 +166,9 @@
     xd = xnee_new_xnee_data();
     ext_xd = xd;

+    /* Set the program name */
+    xnee_set_program_name (xd, GNEE);
+
     /* Set the cli parameters */
     xnee_set_application_parameters (xd, argv);

Peter Fales <psfales>

 

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

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

Only logged-in users can vote.

 

Follow 2 latest changes.

Date Changed by Updated Field Previous Value => Replaced by
2005-12-09 hesa StatusNone Fixed
    Open/ClosedOpen Closed

Back to the top

Powered by Savane 3.13-0329.
Corresponding source code