Update of /cvsroot/spambayes/spambayes/spambayes
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13913/spambayes
Modified Files:
Tag: release_1_0-branch
message.py
Log Message:
Backport:
My patch for Python 2.4 compatibility for the setPayload function wouldn't
work.
This version should. (Need to update the __dict__, note replace it).
Index: message.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/spambayes/message.py,v
retrieving revision 1.49.4.6
retrieving revision 1.49.4.7
diff -C2 -d -r1.49.4.6 -r1.49.4.7
*** message.py 20 Dec 2004 04:09:28 -0000 1.49.4.6
--- message.py 21 Dec 2004 23:12:55 -0000 1.49.4.7
***************
*** 248,252 ****
# 1.0.x branch, so use a different ugly hack.
new_me = email.message_from_string(payload, _class=Message)
! self.__dict__ = new_me.__dict__
def setId(self, id):
--- 248,252 ----
# 1.0.x branch, so use a different ugly hack.
new_me = email.message_from_string(payload, _class=Message)
! self.__dict__.update(new_me.__dict__)
def setId(self, id):
***************
*** 342,347 ****
def setPayload(self, payload):
! new_me = email.message_from_string(payload, _class=Message)
! self.__dict__ = new_me.__dict__
def setIdFromPayload(self):
--- 342,347 ----
def setPayload(self, payload):
! new_me = email.message_from_string(payload, _class=SBHeaderMessage)
! self.__dict__.update(new_me.__dict__)
def setIdFromPayload(self):
_______________________________________________
Spambayes-checkins mailing list
[EMAIL PROTECTED]
http://mail.python.org/mailman/listinfo/spambayes-checkins