summaryrefslogtreecommitdiff
path: root/libavformat/img2dec.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2023-08-31 19:28:10 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2023-09-02 10:36:11 +0200
commitee485b4051c24e2cebe46b426294b346f0f5fff4 (patch)
tree4f7c88a593b99a48255f0703ec67da2b3634ce35 /libavformat/img2dec.c
parent25ecc94d58f8e80137a1243d31b2b98bdeda5039 (diff)
avformat/internal: Don't auto-include os_support.h
It includes various Windows-specific headers when compiling for Windows and these sometimes cause issues: E.g. winbase.h defines IGNORE, which clashes with a macro used in the Matroska muxer (since 884653ee5be03ed38db957c14fad51b300611c8c) and demuxer. This header provides fallback defines for various stuff that is mostly not used directly by (de)muxers at all: mkdir, rename, rmdir, unlink, access, poll, pollfd, nfds_t, closesocket, socklen_t, fstat, stat, lseek, SHUT_(RD|WR|RDWR) and various POLL* constants. Ergo fix this issue by not auto-including this header in lots of places via an inclusion in internal.h and instead include it everywhere where the above stuff is used (most of these translation units already included os_support.h). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavformat/img2dec.c')
-rw-r--r--libavformat/img2dec.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavformat/img2dec.c b/libavformat/img2dec.c
index 15fd67927f..2761cb37a4 100644
--- a/libavformat/img2dec.c
+++ b/libavformat/img2dec.c
@@ -36,6 +36,7 @@
#include "avio_internal.h"
#include "internal.h"
#include "img2.h"
+#include "os_support.h"
#include "libavcodec/jpegxl_parse.h"
#include "libavcodec/mjpeg.h"
#include "libavcodec/vbn.h"