[Python-checkins] python/dist/src/Lib/email __init__.py,1.9,1.10

bwarsaw@users.sourceforge.net bwarsaw@users.sourceforge.net
Thu, 18 Jul 2002 14:29:19 -0700


Update of /cvsroot/python/python/dist/src/Lib/email
In directory usw-pr-cvs1:/tmp/cvs-serv20152

Modified Files:
	__init__.py 
Log Message:
Anthony Baxter's patch to expose the parser's `strict' flag in these
convenience functions.  Closes SF # 583188 (python project).


Index: __init__.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/email/__init__.py,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** __init__.py	9 Jul 2002 02:13:10 -0000	1.9
--- __init__.py	18 Jul 2002 21:29:17 -0000	1.10
***************
*** 5,9 ****
  """
  
! __version__ = '2.1'
  
  __all__ = ['Charset',
--- 5,9 ----
  """
  
! __version__ = '2.2'
  
  __all__ = ['Charset',
***************
*** 33,39 ****
  from email.Message import Message as _Message
  
! def message_from_string(s, _class=_Message):
!     return _Parser(_class).parsestr(s)
  
! def message_from_file(fp, _class=_Message):
!     return _Parser(_class).parse(fp)
--- 33,39 ----
  from email.Message import Message as _Message
  
! def message_from_string(s, _class=_Message, strict=1):
!     return _Parser(_class, strict=strict).parsestr(s)
  
! def message_from_file(fp, _class=_Message, strict=1):
!     return _Parser(_class, strict=strict).parse(fp)