client: Fix another crash bug due to calling memset(this, 0, sizeof(*this)) when the data contains a std::string

svn path=/trunk/boinc/; revision=20109
This commit is contained in:
Charlie Fenton 2010-01-09 00:13:12 +00:00
parent 478aca793f
commit 10a8041371
2 changed files with 8 additions and 1 deletions

View File

@ -208,3 +208,10 @@ Rom 7 Jan 2010
clientgui/
ViewNotifications.cpp
Charlie 6 Jan 2010
- client: Fix another crash bug due to calling memset(this, 0, sizeof(*this))
when the data contains a std::string.
client/
cs_notice.cpp

View File

@ -201,7 +201,7 @@ int NOTICE::parse_rss(XML_PARSER& xp) {
char tag[1024], buf[256];
bool is_tag;
memset(this, 0, sizeof(*this));
clear();
while (!xp.get(tag, sizeof(tag), is_tag)) {
if (!is_tag) continue;
if (!strcmp(tag, "/item")) return 0;