From: rmccabe@sourceware.org <rmccabe@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] conga/ricci/common Module.cpp
Date: 18 Jun 2007 03:54:10 -0000 [thread overview]
Message-ID: <20070618035410.23200.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: conga
Branch: EXPERIMENTAL
Changes by: rmccabe at sourceware.org 2007-06-18 03:54:09
Modified files:
ricci/common : Module.cpp
Log message:
duh.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/common/Module.cpp.diff?cvsroot=cluster&only_with_tag=EXPERIMENTAL&r1=1.5.8.2&r2=1.5.8.3
--- conga/ricci/common/Module.cpp 2007/06/02 04:28:48 1.5.8.2
+++ conga/ricci/common/Module.cpp 2007/06/18 03:54:09 1.5.8.3
@@ -290,27 +290,31 @@
// process event
if (poll_data.revents & POLLIN) {
char buff[4096];
- int ret = read(poll_data.fd, buff, sizeof(buff));
+ int ret;
+
+ ret = read(poll_data.fd, buff, sizeof(buff));
if (ret == -1) {
if (errno == EINTR)
continue;
throw String("error reading stdin: ") + String(strerror(errno));
}
+ if (ret > 0) {
+ data.append(buff, ret);
+ shred(buff, sizeof(buff));
+ }
+
if ((size_t) ret < sizeof(buff)) {
try {
- data.append(buff, ret);
- shred(buff, sizeof(buff));
XMLObject request = parseXML(data);
XMLObject response = module.process(request);
cout << generateXML(response) << endl;
return 0;
- } catch ( ... ) {
- shred(buff, sizeof(buff));
- }
+ } catch ( ... ) { }
}
continue;
}
+
if (poll_data.revents & (POLLERR | POLLHUP | POLLNVAL))
throw String("stdin error: ") + String(strerror(errno));
} // while
reply other threads:[~2007-06-18 3:54 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070618035410.23200.qmail@sourceware.org \
--to=rmccabe@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.