summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2005-04-27 20:34:04 +0000
committerJeremy Katz <katzj@redhat.com>2005-04-27 20:34:04 +0000
commitd14c4b4a431e0b528cc0b3bdd72b6454c36bd04a (patch)
treea67b0089402c9ea73267e1a4a075136ede1f1d7d
parentb49f685e37333985100737be4d5c7a647c937afd (diff)
downloadanaconda-d14c4b4a431e0b528cc0b3bdd72b6454c36bd04a.tar.gz
anaconda-d14c4b4a431e0b528cc0b3bdd72b6454c36bd04a.tar.xz
anaconda-d14c4b4a431e0b528cc0b3bdd72b6454c36bd04a.zip
2005-04-27 Jeremy Katz <katzj@redhat.com>
* iutil.py (writeRpmPlatform): patch from Joe Pruett to improve rpmarch= support (#101971) * iw/ipwidget.py (IPEditor.dehydrate): Make sure people get decimal IP addrs. (#122038)
-rw-r--r--ChangeLog8
-rw-r--r--iutil.py5
-rw-r--r--iw/ipwidget.py12
3 files changed, 23 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 409811282..39d0519fa 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2005-04-27 Jeremy Katz <katzj@redhat.com>
+
+ * iutil.py (writeRpmPlatform): patch from Joe Pruett to improve
+ rpmarch= support (#101971)
+
+ * iw/ipwidget.py (IPEditor.dehydrate): Make sure people get
+ decimal IP addrs. (#122038)
+
2004-04-27 Chris Lumens <clumens@redhat.com>
* docs/kickstart-docs.txt: Updated for new --label parameter.
diff --git a/iutil.py b/iutil.py
index 7711ade05..230ca2a33 100644
--- a/iutil.py
+++ b/iutil.py
@@ -662,10 +662,13 @@ def writeRpmPlatform(root="/"):
f = open("/proc/cmdline", "r")
buf = f.read()
f.close()
- args = buf.split(" ")
+ args = buf.split()
for arg in args:
if arg.startswith("rpmarch="):
myarch = arg[8:]
+
+ # now make the current install believe it, too
+ rhpl.arch.canonArch = myarch
f = open("%s/etc/rpm/platform" %(root,), 'w+')
f.write("%s-redhat-linux\n" %(myarch,))
diff --git a/iw/ipwidget.py b/iw/ipwidget.py
index f64055991..a0d70bffd 100644
--- a/iw/ipwidget.py
+++ b/iw/ipwidget.py
@@ -103,7 +103,17 @@ class IPEditor:
except ValueError, msg:
raise IPError, (_("IP Addresses must contain numbers between 0 and 255"), widget)
- return self.entrys['entry1'].get_text() + "." + self.entrys['entry2'].get_text() + "." +self.entrys['entry3'].get_text() + "." +self.entrys['entry4'].get_text()
+ ents = []
+ for ent in (self.entrys['entry1'].get_text(),
+ self.entrys['entry2'].get_text(),
+ self.entrys['entry3'].get_text(),
+ self.entrys['entry4'].get_text()):
+ if ent != "0":
+ ents.append(ent.lstrip("0"))
+ else:
+ ents.append(ent)
+
+ return "%s.%s.%s.%s" %(ents[0], ents[1], ents[2], ents[3])
def entry_insert_text_cb(self, entry, text, length, pos, next):
if text == '.':