summaryrefslogtreecommitdiffabout
path: root/lib/sitecing_interface_cgi.cc
Unidiff
Diffstat (limited to 'lib/sitecing_interface_cgi.cc') (more/less context) (ignore whitespace changes)
-rw-r--r--lib/sitecing_interface_cgi.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/sitecing_interface_cgi.cc b/lib/sitecing_interface_cgi.cc
index 59ae25a..1acb23c 100644
--- a/lib/sitecing_interface_cgi.cc
+++ b/lib/sitecing_interface_cgi.cc
@@ -21,7 +21,9 @@ namespace sitecing {
21 flush_headers(); 21 flush_headers();
22 if(is_buffering()) { 22 if(is_buffering()) {
23 streampos count = prebuffer.pubseekoff(0,ios_base::cur,ios_base::out); 23 streampos count = prebuffer.pubseekoff(0,ios_base::cur,ios_base::out);
24 cgigw->out().write(prebuffer.str().c_str(),count); 24 if(count>0) {
25 cgigw->out().write(prebuffer.str().c_str(),count);
26 }
25 prebuffer.str(""); 27 prebuffer.str("");
26 } 28 }
27 cgigw->out().flush(); 29 cgigw->out().flush();