Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Noted an additional modification we have made to `make_msgid`.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@7349 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 6e2c677ef95e720692cf34c310110a9e698d3b07 1 parent c364b6b
Gary Wilson Jr. authored March 21, 2008

Showing 1 changed file with 4 additions and 3 deletions. Show diff stats Hide diff stats

  1. 7  django/core/mail.py
7  django/core/mail.py
@@ -38,8 +38,9 @@ def get_fqdn(self):
38 38
 
39 39
 DNS_NAME = CachedDnsName()
40 40
 
41  
-# Copied from Python standard library and modified to used the cached hostname
42  
-# for performance.
  41
+# Copied from Python standard library, with the following modifications:
  42
+# * Used cached hostname for performance.
  43
+# * Added try/except to support lack of getpid() in Jython (#5496).
43 44
 def make_msgid(idstring=None):
44 45
     """Returns a string suitable for RFC 2822 compliant Message-ID, e.g:
45 46
 
@@ -53,7 +54,7 @@ def make_msgid(idstring=None):
53 54
     try:
54 55
         pid = os.getpid()
55 56
     except AttributeError:
56  
-        # Not getpid() in Jython, for example.
  57
+        # No getpid() in Jython, for example.
57 58
         pid = 1
58 59
     randint = random.randrange(100000)
59 60
     if idstring is None:

0 notes on commit 6e2c677

Please sign in to comment.
Something went wrong with that request. Please try again.