diff mbox series

[FFmpeg-devel,v4,1/5] Add documentation for ff_neterrno()

Message ID 20240516093403.3763258-2-ffmpeg-devel@pileofstuff.org
State New
Headers show
Series avformat/network: improve ff_neterrno() | expand

Checks

Context Check Description
yinshiyou/commit_msg_loongarch64 warning The first line of the commit message must start with a context terminated by a colon and a space, for example "lavu/opt: " or "doc: ".
andriy/commit_msg_x86 warning The first line of the commit message must start with a context terminated by a colon and a space, for example "lavu/opt: " or "doc: ".
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Andrew Sayers May 16, 2024, 9:33 a.m. UTC
---
 libavformat/network.h | 10 ++++++++++
 1 file changed, 10 insertions(+)
diff mbox series

Patch

diff --git a/libavformat/network.h b/libavformat/network.h
index ca214087fc..728c20c9bb 100644
--- a/libavformat/network.h
+++ b/libavformat/network.h
@@ -57,6 +57,11 @@ 
 #define getsockopt(a, b, c, d, e) getsockopt(a, b, c, (char*) d, e)
 #define setsockopt(a, b, c, d, e) setsockopt(a, b, c, (const char*) d, e)
 
+/*
+ * @brief AVERROR for the latest network function
+ * @return platform-specific AVERROR value
+ * @note Error is based on WSAGetLastError() (Windows) or `errno` (otherwise)
+ */
 int ff_neterrno(void);
 #else
 #include <sys/types.h>
@@ -65,6 +70,11 @@  int ff_neterrno(void);
 #include <netinet/tcp.h>
 #include <netdb.h>
 
+/*
+ * @brief AVERROR for the latest network function
+ * @return platform-specific AVERROR value
+ * @note Error is based on WSAGetLastError() (Windows) or `errno` (otherwise)
+ */
 #define ff_neterrno() AVERROR(errno)
 #endif /* HAVE_WINSOCK2_H */