shithub: opusfile

Download patch

ref: 3b3b3e5519bbb235df3fb457818337160a8ca260
parent: 529bd01294c13a62f13fc4fe882eec175fc0bebc
author: Timothy B. Terriberry <tterribe@xiph.org>
date: Wed May 24 09:08:44 EDT 2017

Fix two compiler warnings.

Thanks to Mark Harris for the report.

--- a/src/http.c
+++ b/src/http.c
@@ -3422,6 +3422,7 @@
   proxy_user=NULL;
   proxy_pass=NULL;
   pinfo=NULL;
+  *_pinfo=NULL;
   for(;;){
     ptrdiff_t request;
     request=va_arg(_ap,char *)-(char *)NULL;
@@ -3453,7 +3454,6 @@
   }
   /*If the caller has requested server information, proxy it to a local copy to
      simplify error handling.*/
-  *_pinfo=NULL;
   if(pinfo!=NULL){
     void *ret;
     opus_server_info_init(_info);
--- a/src/info.c
+++ b/src/info.c
@@ -115,7 +115,7 @@
   /*We only support growing.
     Trimming requires cleaning up the allocated strings in the old space, and
      is best handled separately if it's ever needed.*/
-  OP_ASSERT(_ncomments>=cur_ncomments);
+  OP_ASSERT(_ncomments>=(size_t)cur_ncomments);
   comment_lengths=_tags->comment_lengths;
   comment_lengths=(int *)_ogg_realloc(_tags->comment_lengths,size);
   if(OP_UNLIKELY(comment_lengths==NULL))return OP_EFAULT;