Don't send an empty message if there is no message to send.

svn path=/trunk/boinc/; revision=5274
This commit is contained in:
Bruce Allen 2005-02-02 15:16:59 +00:00
parent 1d9d71cce4
commit 02d0ac6fd8
1 changed files with 6 additions and 4 deletions

View File

@ -342,10 +342,12 @@ int SCHEDULER_REPLY::write(FILE* fout) {
pri = "high";
}
}
fprintf(fout,
"<message priority=\"%s\">%s</message>\n",
pri.c_str(), msg.c_str()
);
if (messages.size()>0) {
fprintf(fout,
"<message priority=\"%s\">%s</message>\n",
pri.c_str(), msg.c_str()
);
}
} else {
for (i=0; i<messages.size(); i++) {
USER_MESSAGE& um = messages[i];