Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 
 

23 řádky
518 B

  1. #pragma once
  2. #include "response.h"
  3. #include "../types.h"
  4. namespace cppmicrohttpd
  5. {
  6. /* response */
  7. response::response(const request_t& p_request)
  8. : request (p_request)
  9. , handle (nullptr, &MHD_destroy_response)
  10. { }
  11. void response::add_header(const char * key, const char * value)
  12. {
  13. if (MHD_add_response_header(handle.get(), key, value) != MHD_YES)
  14. throw exception(std::string("Unable to add header entry in response: ") + key + "=" + value);
  15. }
  16. }