bugXnee - Bugs: bug #23965, Uninitialized variable in cnee

 
 

bug #23965: Uninitialized variable in cnee

Submitter:  Peter Fales <psfales>
Submitted:  Wed 30 Jul 2008 11:38:46 AM UTC
   
 
Category:  cnee Severity:  3 - Normal
Item Group:  Minor fault Status:  Fixed
Privacy:  Public Assigned to:  hesa
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 01 Aug 2008 09:52:13 PM UTC, comment #1: 

Thanks.

It's fixed. Will commit when I have a better internet connection (CVS diff takes for ever).

/hesa

Henrik Sandklef <hesa>
Group administrator
Wed 30 Jul 2008 11:38:46 AM UTC, original submission:  

If one types "cnee" with no arguments, the value of an un-initialzied pointer is printed.  On Linux, the results in garbabe printed on the screen:

$ cnee
Error number:   6
  Error:        Wrong paramters
  Description:  You have given invalid input to Xnee
  Argument:     X)Ê¿

I used this patch:

diff -ur xnee-3.02/cnee/src/parse.c xnee-3.02.new/cnee/src/parse.c
--- xnee-3.02/cnee/src/parse.c  2007-06-28 05:14:17.000000000 -0500
+++ xnee-3.02.new/cnee/src/parse.c      2008-07-29 22:40:01.000000000 -0500
@@ -522,7 +522,7 @@
   const char *descr;
   const char *err;
   const char *sol;
-  char *saved_arg;
+  char *saved_arg = "(NONE)";
   int entry ;
   int args_used;
 

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

 

Carbon-Copy List
  • -email is unavailable- added by hesa (Posted a comment)
  • -email is unavailable- added by psfales (Submitted the item)
  •  

    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 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2009-11-01 hesa Open/ClosedOpen Closed
    2008-08-01 hesa StatusNone Fixed
        Assigned toNone hesa

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code