The branch, master has been updated
       via  b815431126c8feb7557f61bb16bf6b572993089a (commit)
      from  db6cd6c6bfe6f306dd8d9de2a0086586cbd27ec1 (commit)


- Log -----------------------------------------------------------------
commit b815431126c8feb7557f61bb16bf6b572993089a
Author:     Andreas Rheinhardt <[email protected]>
AuthorDate: Thu Sep 18 14:58:55 2025 +0200
Commit:     Andreas Rheinhardt <[email protected]>
CommitDate: Mon Sep 22 22:02:03 2025 +0200

    Revert "avformat/tls_openssl: add av_assert0() for tls_shared"
    
    This reverts commits fd55c4b5f72a157fbb128d0ef203e9922b53552b
    (for tls_openssl.c) and c74181a04b5f4e650eae662231e56518daef64d4
    (for tls_gnutls.c).
    
    It is impossible for a pointer to a member of a structure
    to be NULL: If the containing structure exists, the member
    exists and can't have a NULL address; if the containing
    structure does not exist, then getting a pointer to the
    substructure via &c->tls_shared would already be undefined
    behavior.
    
    Reviewed-by: Kacper Michajłow <[email protected]>
    Reviewed-by: Steven Liu <[email protected]>
    Signed-off-by: Andreas Rheinhardt <[email protected]>

diff --git a/libavformat/tls_gnutls.c b/libavformat/tls_gnutls.c
index fe2fd53291..e4fe53318c 100644
--- a/libavformat/tls_gnutls.c
+++ b/libavformat/tls_gnutls.c
@@ -30,7 +30,6 @@
 #include "os_support.h"
 #include "url.h"
 #include "tls.h"
-#include "libavutil/avassert.h"
 #include "libavutil/opt.h"
 #include "libavutil/thread.h"
 
@@ -156,7 +155,6 @@ static int tls_open(URLContext *h, const char *uri, int 
flags, AVDictionary **op
     TLSShared *s = &c->tls_shared;
     uint16_t gnutls_flags = 0;
     int ret;
-    av_assert0(s);
 
     ff_gnutls_init();
 
@@ -262,7 +260,6 @@ static int dtls_open(URLContext *h, const char *uri, int 
flags, AVDictionary **o
 {
     TLSContext *c = h->priv_data;
     TLSShared *s = &c->tls_shared;
-    av_assert0(s);
     s->is_dtls = 1;
     return tls_open(h, uri, flags, options);
 }
diff --git a/libavformat/tls_openssl.c b/libavformat/tls_openssl.c
index 86b4d21799..5fc0b639d7 100644
--- a/libavformat/tls_openssl.c
+++ b/libavformat/tls_openssl.c
@@ -20,7 +20,6 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/avassert.h"
 #include "libavutil/mem.h"
 #include "network.h"
 #include "os_support.h"
@@ -746,7 +745,6 @@ static int dtls_start(URLContext *h, const char *url, int 
flags, AVDictionary **
     TLSContext *c = h->priv_data;
     TLSShared *s = &c->tls_shared;
     int ret = 0;
-    av_assert0(s);
     s->is_dtls = 1;
 
     c->ctx = SSL_CTX_new(s->listen ? DTLS_server_method() : 
DTLS_client_method());
@@ -847,7 +845,6 @@ static int tls_open(URLContext *h, const char *uri, int 
flags, AVDictionary **op
     TLSShared *s = &c->tls_shared;
     int ret;
 
-    av_assert0(s);
     if ((ret = ff_tls_open_underlying(s, h, uri, options)) < 0)
         goto fail;
 

-----------------------------------------------------------------------

Summary of changes:
 libavformat/tls_gnutls.c  | 3 ---
 libavformat/tls_openssl.c | 3 ---
 2 files changed, 6 deletions(-)


hooks/post-receive
-- 

_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to