Bug 432395

Summary: visudo reports incorrect line numbers in error messages
Product: [Fedora] Fedora Reporter: Joe Krahn <krahn>
Component: sudoAssignee: Peter Vrabec <pvrabec>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: 7CC: kzak
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-02-21 16:46:22 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 Joe Krahn 2008-02-11 19:43:27 UTC
Description of problem:
If an error is found by 'visudo', it gives an error with the line number.
However, it fails to count lines continued with backslashes, which are used in
the installed defaults. It also starts off counting the first line as 2. My
guess is that the latter is a known problem, because the error message states
"... near line %d", but maybe this could be fixed as well.

Version-Release number of selected component (if applicable):
sudo-1.6.8p12-14.fc7

How reproducible:
Always

Steps to Reproduce:
1. run visudo
2. put an intentional typo at the end of the file
3. save
  
Actual results:
>>> sudoers file: syntax error, line 89 <<<

Expected results:
>>> sudoers file: syntax error, line 94 <<<


Additional info:

Comment 1 Peter Vrabec 2008-02-21 16:46:22 UTC

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