Bug 140979 - local variable used before set
Summary: local variable used before set
Keywords:
Status: CLOSED DUPLICATE of bug 153079
Alias: None
Product: Fedora
Classification: Fedora
Component: unix2dos
Version: 3
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Tim Waugh
QA Contact: Ben Levenson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-11-27 10:19 UTC by David Binderman
Modified: 2007-11-30 22:10 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2005-04-12 13:55:09 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description David Binderman 2004-11-27 10:19:39 UTC
Description of problem:

I just tried to compile package unix2dos-2.2-24 from 
Redhat Fedora Core 3.

The compiler said

unix2dos.c(253): remark #592: variable "TempPath" is used before its
value is set

The source code is

  char *TempPath;
  struct stat StatBuf;
  struct utimbuf UTimeBuf;
  int fd;

  /* retrieve ipInFN file date stamp */
  if ((ipFlag->KeepDate) && stat(ipInFN, &StatBuf))
    RetVal = -1;

  strcpy (TempPath, "./u2dtmpXXXXXX");

Suggest init TempPath before first use.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Tim Waugh 2005-04-12 13:55:09 UTC

*** This bug has been marked as a duplicate of 153079 ***


Note You need to log in before you can comment on or make changes to this bug.