Bug 169819 - Trailing space in host name causes crash
Trailing space in host name causes crash
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: system-config-network (Show other bugs)
4
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Harald Hoyer
:
Depends On:
Blocks: 87718
  Show dependency treegraph
 
Reported: 2005-10-03 23:44 EDT by Tom Morton
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-07-24 07:44:03 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Tom Morton 2005-10-03 23:44:39 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.12) Gecko/20050922 Fedora/1.0.7-1.1.fc4 Firefox/1.0.7

Description of problem:
When entering a host in the hosts tab if a trailing space is placed on the
host name the network configuration to crashes

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

How reproducible:
Always

Steps to Reproduce:
1. Enter an IP for a new host
2. Enter a name with a trailing space
3. Enter an alias
4. Save
  

Actual Results:  /etc/hosts file isn't updated and the following error message is displayed:

Component: system-config-network
Version: 1.3.26
Summary: TBd7ebbbe6 Conf.py:596:__delitem__:KeyError: 'machine.domain.com'

Traceback (most recent call last):
  File "/usr/src/build/556832-noarch/install/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 797, in on_applyButton_clicked
  File "/usr/src/build/556832-noarch/install/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 372, in save
  File "/usr/src/build/556832-noarch/install/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 404, in saveProfiles
  File "/usr/src/build/556832-noarch/install/usr/share/system-config-network/netconfpkg/NCProfileList.py", line 388, in save
  File "/usr/lib/python2.4/site-packages/rhpl/Conf.py", line 596, in __delitem__
    del self.vars[varname]
KeyError: 'machine.domain.com'

Local variables in innermost frame:
varname: machine.domain.com
self: <rhpl.Conf.ConfFHosts instance at 0xb79d856c>

Expected Results:  /etc/hosts file saved sans crash

Additional info:

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