bugXnee - Bugs: bug #8324, --retype-file option for cnee does...

 
 

bug #8324: --retype-file option for cnee does not set mode

Submitter:  Joseph Miele <jemiele1>
Submitted:  Sat 27 Mar 2004 08:07:13 AM UTC
   
 
Category:  cnee Severity:  3 - Normal
Item Group:  Error report Status:  Fixed
Privacy:  Public Assigned to:  hesa
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Tue 30 Mar 2004 07:33:19 PM UTC, comment #1: 

Yes, this is the way to do it. Will include it.....


Henrik Sandklef <hesa>
Group administrator
Sat 27 Mar 2004 08:07:13 AM UTC, original submission:  

Problem: Option "--retype-file" fails to set the mode, causing the option to fail.

Version affected: CVS

Steps to reproduce the bug:
1. Create text file /tmp/test.xnee. The contents of the file do not matter.
2. Enter the following command:
cnee --verbose --retype-file /tmp/test.xnee

One of the lines of the verbose output will be: "No mode specified... leaving".

Cause: Missing call to xnee_set_retyper in file parse.c (directory cnee/src)

Here is the corrected code segment for parse.c:

      else if(xnee_check(argv[i], "--retype-file", "-rtf" ))
        {
          xnee_set_retyper(xd); /* this is the fix */
          if (++i >= argc)
            {
              xnee_usage(stderr);
              xnee_close_down(xd);
              exit(XNEE_WRONG_PARAMS);
            }
          if ( xnee_set_rt_name (xd, argv[i]) != XNEE_OK)
            {
              xnee_print_error ("Unable to open retype file\n");
              xnee_verbose ((xd, "Could not open retype file\n"));
              xnee_verbose ((xd, "... leaving\n"));
              xnee_close_down(xd);
              exit(XNEE_WRONG_PARAMS);
            }
          continue;

        }

Notice the new line designated as the fix. Adding this line solved the problem for me. Running cnee as indicated in step 2 works correctly with this change in place.

Please review this code change. If you find the fix acceptable, please update CVS.

Thank you for your time.

Joseph Miele <jemiele1>

 

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

Date Changed by Updated Field Previous Value => Replaced by
2004-04-18 hesa StatusNone Fixed
    Assigned toNone hesa
    Open/ClosedOpen Closed

Back to the top

Powered by Savane 3.13-4b48.
Corresponding source code