Bug 84917 - tool bombs on blank lines
tool bombs on blank lines
Status: CLOSED DUPLICATE of bug 83408
Product: Red Hat Linux
Classification: Retired
Component: redhat-config-nfs (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Brent Fox
Depends On:
Blocks: 79578
  Show dependency treegraph
Reported: 2003-02-23 16:15 EST by Gordon Messmer
Modified: 2008-05-01 11:38 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-02-21 13:51:57 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
simple patch to make the program ignore blank lines (724 bytes, patch)
2003-02-23 16:18 EST, Gordon Messmer
no flags Details | Diff
patch to improve the nfs data classes (5.91 KB, patch)
2003-02-23 16:20 EST, Gordon Messmer
no flags Details | Diff

  None (edit)
Description Gordon Messmer 2003-02-23 16:15:14 EST
Description of problem:
If /etc/exports contains a blank line, the program will crash.

The program will also crash if there's a line with less than
two tokens from the initial split and otherwise doesn't handle
some files which may have been previously set up by hand,
(or in some cases by the tool itself).

The UI is also broken, such that it is not suitable for configuring
options for more than one host.  I'm attaching two patches.  The 
first just makes the program not crash on blank lines.  The second
is a revision to the parser (nfsBackend.py) and the data class
(nfsData.py) to make the tool more robust.  However, the patch doesn't
produce a working tool, since the UI needs to be updated to use
the better backend.  I'm not sure exactly how that should happen.
Maybe change the "hosts" item on the properties window into a combo
box with each host and re-populate the options on change?

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

How reproducible:

Steps to Reproduce:
1. Start the tool when there's a blank line in /etc/exports
Comment 1 Gordon Messmer 2003-02-23 16:18:07 EST
Created attachment 90298 [details]
simple patch to make the program ignore blank lines
Comment 2 Gordon Messmer 2003-02-23 16:20:07 EST
Created attachment 90299 [details]
patch to improve the nfs data classes

In order for this to be useful, the UI must also be fixed to get a list of the
hosts in the NFS export, and configure them individually.
Comment 3 Brent Fox 2003-02-24 16:31:25 EST

*** This bug has been marked as a duplicate of 83408 ***
Comment 4 John Stracke 2003-02-25 22:11:47 EST
Only part of this bug is a duplicate of 83408; the problem of not being able to
handle multiple hosts per entry is distinct.  I've had this problem, too; the UI
says "Hosts", but, if you enter a comma-separated list of hosts, you generate an
invalid /etc/exports.  The only solution (other than giving up on the GUI tool)
is to add multiple entries, one per host.  There isn't even a Duplicate command.
 So, unless the set of hosts you want to apply an entry to matches what
/etc/exports can handle natively (*.domain.example.com, or 192.168.0.*, or an
NIS group--not that common these days), if you have a lot of hosts to handle,
the GUI becomes less useful than, say, vi.
Comment 5 Red Hat Bugzilla 2006-02-21 13:51:57 EST
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.

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