Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 96009 - sed prints incorrect reference number when the reference is invalid
Summary: sed prints incorrect reference number when the reference is invalid
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All All
: High normal
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-06-13 13:20 UTC by Emanuele Giaquinta (RETIRED)
Modified: 2005-06-13 16:16 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
sed.diff (sed.diff,479 bytes, patch)
2005-06-13 13:21 UTC, Emanuele Giaquinta (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Emanuele Giaquinta (RETIRED) gentoo-dev 2005-06-13 13:20:55 UTC
When using a \N reference with the 's' command and the reference is invalid sed prints N + 1 as the invalid reference number.You can test it easily with the following command:

echo 'something' | sed 's/\(.*\)/\2/'

The attached patch, from upstream, fixes the issue.
Comment 1 Emanuele Giaquinta (RETIRED) gentoo-dev 2005-06-13 13:21:31 UTC
Created attachment 61164 [details, diff]
sed.diff
Comment 2 Chris White (RETIRED) gentoo-dev 2005-06-13 13:38:48 UTC
Base system re-assignment.
Comment 3 Chris White (RETIRED) gentoo-dev 2005-06-13 13:38:58 UTC
Base system re-assignment.
Comment 4 SpanKY gentoo-dev 2005-06-13 16:16:37 UTC
thanks, added to 4.1.4