Skip to content

Commit

Permalink
[core] Fix some indirect inclusion issues (#2906).
Browse files Browse the repository at this point in the history
* Removed unnecessary include of srt_compat.h from srt.h.
* Removed include of srt_compat.h and directly added it where it belongs.
* Added srt_compat.h include to srt-test-live.
* Added cstddef include to packet.cpp.
  • Loading branch information
yomnes0 authored Mar 8, 2024
1 parent 9b8aaa6 commit 2c3f6f9
Show file tree
Hide file tree
Showing 8 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion apps/srt-live-transmit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
#include <thread>
#include <list>


#include "srt_compat.h"
#include "apputil.hpp" // CreateAddr
#include "uriparser.hpp" // UriParser
#include "socketoptions.hpp"
Expand Down
1 change: 1 addition & 0 deletions apps/srt-tunnel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#include <mutex>
#include <condition_variable>

#include "srt_compat.h"
#include "apputil.hpp" // CreateAddr
#include "uriparser.hpp" // UriParser
#include "socketoptions.hpp"
Expand Down
2 changes: 0 additions & 2 deletions srtcore/common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,6 @@ modified by
#include "packet.h"
#include "threadname.h"

#include <srt_compat.h> // SysStrError

using namespace std;
using namespace srt::sync;
using namespace srt_logging;
Expand Down
2 changes: 1 addition & 1 deletion srtcore/logging.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ written by
*****************************************************************************/



#include "srt_compat.h"
#include "logging.h"

using namespace std;
Expand Down
1 change: 0 additions & 1 deletion srtcore/logging.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ written by
#include "utilities.h"
#include "threadname.h"
#include "logging_api.h"
#include "srt_compat.h"
#include "sync.h"

#ifdef __GNUC__
Expand Down
2 changes: 1 addition & 1 deletion srtcore/packet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ modified by
// the original sequence numbers in the field.

#include "platform_sys.h"

#include <cstddef>
#include <cstring>
#include "packet.h"
#include "handshake.h"
Expand Down
2 changes: 0 additions & 2 deletions srtcore/srt.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ written by

#include "platform_sys.h"

#include "srt_compat.h"

#include <string.h>
#include <stdlib.h>

Expand Down
1 change: 1 addition & 0 deletions testing/srt-test-live.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
#include <chrono>
#include <thread>

#include "srt_compat.h"
#include "apputil.hpp"
#include "uriparser.hpp" // UriParser
#include "socketoptions.hpp"
Expand Down

0 comments on commit 2c3f6f9

Please sign in to comment.