summaryrefslogtreecommitdiff
path: root/trunk/src
diff options
context:
space:
mode:
authorfuzzyray <fuzzyray@gentoo.org>2008-03-19 19:36:03 +0000
committerfuzzyray <fuzzyray@gentoo.org>2008-03-19 19:36:03 +0000
commit4312c942d4deb2a9f226fdb0ff3851d2b311b16e (patch)
treecd808371a976ce53a9e7f699da9a55862abecbc6 /trunk/src
parentbfa5d8fd0cdb1b2a8a5b8eaf68a6e44c01d53e74 (diff)
downloadgentoolkit-4312c942d4deb2a9f226fdb0ff3851d2b311b16e.tar.gz
Fix imports so mail functionality in glsa-check works with python versions less than 2.5 (Bug 211706)
svn path=/; revision=485
Diffstat (limited to 'trunk/src')
-rw-r--r--trunk/src/glsa-check/glsa-check7
1 files changed, 5 insertions, 2 deletions
diff --git a/trunk/src/glsa-check/glsa-check b/trunk/src/glsa-check/glsa-check
index 241d3cb..98e5708 100644
--- a/trunk/src/glsa-check/glsa-check
+++ b/trunk/src/glsa-check/glsa-check
@@ -313,8 +313,11 @@ if mode == "mail":
import socket
from StringIO import StringIO
- from email.mime.text import MIMEText
-
+ try:
+ from email.mime.text import MIMEText
+ except ImportError:
+ from email.MIMEText import MIMEText
+
# color doesn't make any sense for mail
nocolor()