crossroads

Git mirror of https://crossroads.e-tunity.com/
git clone git://git.finwo.net/app/crossroads
Log | Files | Refs | LICENSE

addheader.cc (320B)


      1 #include "httpbuffer"
      2 
      3 void Httpbuffer::addheader (string const &var, string const &val) {
      4     PROFILE("Httpbuffer::addheader(string,string)");
      5 
      6     if (!headersreceived())
      7 	return;
      8     
      9     string old = headerval(var);
     10     if (old.size()) {
     11 	old += ", " + val;
     12 	setheader(var, old);
     13     } else
     14 	setheader (var, val);
     15 }