vlc | branch: master | Thomas Guillem <tho...@gllm.fr> | Tue Mar  2 15:43:09 
2021 +0100| [c26c7de515f5e0622101d26cf6faf59daab8c66f] | committer: Thomas 
Guillem

smb2: use INET_ADDRSTRLEN directly

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c26c7de515f5e0622101d26cf6faf59daab8c66f
---

 modules/access/smb2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/access/smb2.c b/modules/access/smb2.c
index 0b7f75906a..0fc7ece473 100644
--- a/modules/access/smb2.c
+++ b/modules/access/smb2.c
@@ -632,7 +632,7 @@ vlc_smb2_resolve(stream_t *access, const char *host, 
unsigned port)
     uint32_t ip4_addr;
     if (netbios_ns_resolve(ns, host, NETBIOS_FILESERVER, &ip4_addr) == 0)
     {
-        char ip[] = "xxx.xxx.xxx.xxx";
+        char ip[INET_ADDRSTRLEN];
         if (inet_ntop(AF_INET, &ip4_addr, ip, sizeof(ip)))
             out_host = strdup(ip);
     }

_______________________________________________
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to