Bug 73574

Summary: problems renaming temporary file
Product: [Retired] Red Hat Linux Reporter: Need Real Name <vooren>
Component: unix2dosAssignee: wdovlrrw <brosenkr>
Status: CLOSED RAWHIDE QA Contact: Ben Levenson <benl>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.2   
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2002-09-06 07:46:39 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Need Real Name 2002-09-06 07:46:25 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.78 [en] (X11; U; Linux 2.4.7-10 i686)

Description of problem:
If I use unix2dos 'file' (the same problem arises with dos2unix) and the file is
on a different filesystem than my pwd, I get the following error:
unix2dos: converting file /tmp/test to DOS format ...
unix2dos: problems renaming './u2dtmpt24PqZ' to '/tmp/test'
          output file remains in './u2dtmpt24PqZ'
unix2dos: problems converting file /tmp/test

I do have write permissions in my pwd (if I don't, I get a segmentation fault -
creating the temporary file in the pwd is maybe not the best solution).

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


How reproducible:
Always

Steps to Reproduce:
1. 'cd' to a directory on another filesystem than the one containing the file to
be "unix2dossed"
2. execute unix2dos 'file'
3.
	

Actual Results:  The temporary file can't be renamed to the target file

Expected Results:  A rename of the temporary file to the target file

Additional info:

unix2dos-2.2-12
dos2unix-3.1-7

unix2dos: converting file /tmp/test to DOS format ...
unix2dos: problems renaming './u2dtmpt24PqZ' to '/tmp/test'
          output file remains in './u2dtmpt24PqZ'
unix2dos: problems converting file /tmp/test

Comment 1 Bernhard Rosenkraenzer 2002-09-12 11:34:05 UTC
This was fixed in the current version.