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.

41 lines
1.7 KiB

  1. From f0f04b7315f59b3a9b814c13c705d4354d0c0626 Mon Sep 17 00:00:00 2001
  2. From: mpromonet <michel.promonet@free.fr>
  3. Date: Fri, 27 Nov 2020 19:36:43 +0100
  4. Subject: [PATCH] fix #216: allow to build with live555 newer than 2020.11.27
  5. (2020.11.25 & 2020.11.26 doesnot build)
  6. ---
  7. inc/HTTPServer.h | 9 +++++++--
  8. 1 file changed, 7 insertions(+), 2 deletions(-)
  9. --- a/inc/HTTPServer.h
  10. +++ b/inc/HTTPServer.h
  11. @@ -113,13 +113,18 @@ class TCPSink: public MediaSink {
  12. // ---------------------------------------------------------
  13. // Extend RTSP server to add support for HLS and MPEG-DASH
  14. // ---------------------------------------------------------
  15. +#if LIVEMEDIA_LIBRARY_VERSION_INT < 1606435200
  16. +#define SOCKETCLIENT sockaddr_in
  17. +#else
  18. +#define SOCKETCLIENT sockaddr_storage
  19. +#endif
  20. class HTTPServer : public RTSPServer
  21. {
  22. class HTTPClientConnection : public RTSPServer::RTSPClientConnection
  23. {
  24. public:
  25. - HTTPClientConnection(RTSPServer& ourServer, int clientSocket, struct sockaddr_in clientAddr)
  26. + HTTPClientConnection(RTSPServer& ourServer, int clientSocket, struct SOCKETCLIENT clientAddr)
  27. : RTSPServer::RTSPClientConnection(ourServer, clientSocket, clientAddr), m_TCPSink(NULL), m_StreamToken(NULL), m_Subsession(NULL), m_Source(NULL) {
  28. }
  29. virtual ~HTTPClientConnection();
  30. @@ -165,7 +170,7 @@ class HTTPServer : public RTSPServer
  31. }
  32. }
  33. - RTSPServer::RTSPClientConnection* createNewClientConnection(int clientSocket, struct sockaddr_in clientAddr)
  34. + RTSPServer::RTSPClientConnection* createNewClientConnection(int clientSocket, struct SOCKETCLIENT clientAddr)
  35. {
  36. return new HTTPClientConnection(*this, clientSocket, clientAddr);
  37. }