Bug 205122 - sed failes to update link files which are not a full path link.
Summary: sed failes to update link files which are not a full path link.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: sed
Version: 5
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Petr Machata
QA Contact: Ben Levenson
URL:
Whiteboard:
Depends On:
Blocks: 205134
TreeView+ depends on / blocked
 
Reported: 2006-09-04 12:04 UTC by Vladimir Sokolovsky
Modified: 2015-05-05 01:32 UTC (History)
1 user (show)

Fixed In Version: FC-5
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-09-04 15:50:47 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Fix (1.60 KB, patch)
2006-09-04 15:16 UTC, Petr Machata
no flags Details | Diff

Description Vladimir Sokolovsky 2006-09-04 12:04:51 UTC
Description of problem:
sed failes to update link files which are not a full path link.

Version-Release number of selected component (if applicable):
sed-4.1.5-4.fc5

How reproducible:
Every time

Steps to Reproduce:
1. cd /root
2. mkdir test
3. echo zzz > test/test.txt
4. ln -s test/test.txt test.link
5. cd /tmp
6. sed -i -e 's/zzz/aaa/g' /root/test.link
sed: ck_follow_symlink: couldn't lstat test/test.txt: No such file or directory

Actual results:
sed: ck_follow_symlink: couldn't lstat test/test.txt: No such file or directory

Expected results:


Additional info:
The same command works on FedoraC4: sed-4.1.2-4

Comment 1 Petr Machata 2006-09-04 15:16:13 UTC
Created attachment 135502 [details]
Fix

sed now looks if the symlinks begins with '/', and if not, it does relative
path traversal. It was applied to devel cvs tree and will appear in rawhide.

Comment 2 Petr Machata 2006-09-04 15:50:47 UTC
I did a FC5 build. It should appear in testing in a day or two.


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