You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
1000 B

  1. --- a/webservice.hpp
  2. +++ b/webservice.hpp
  3. @@ -38,13 +38,13 @@ class WebService {
  4. MHD_Daemon* daemon;
  5. Functor functor;
  6. - static int on_request(void * cls, struct MHD_Connection * connection, const char * url, const char * method, const char * version,
  7. + static enum MHD_Result on_request(void * cls, struct MHD_Connection * connection, const char * url, const char * method, const char * version,
  8. const char * upload_data, size_t * upload_data_size,
  9. void ** ptr);
  10. };
  11. template <typename Functor>
  12. -int WebService<Functor>::on_request(void * cls,
  13. +enum MHD_Result WebService<Functor>::on_request(void * cls,
  14. struct MHD_Connection * connection,
  15. const char * url,
  16. const char * method,
  17. @@ -53,7 +53,7 @@ int WebService<Functor>::on_request(void
  18. size_t * upload_data_size,
  19. void ** ptr) {
  20. static int dummy;
  21. - int ret;
  22. + enum MHD_Result ret;
  23. if (std::string("GET") != method)
  24. return MHD_NO; /* unexpected method */