[Lldb-commits] [lldb] 000e790 - [lldb] Fixed IPv6 host formatting in #104238 (#111033)

via lldb-commits lldb-commits at lists.llvm.org
Thu Oct 3 11:23:15 PDT 2024


Author: Dmitry Vasilyev
Date: 2024-10-03T22:23:12+04:00
New Revision: 000e790be35b77a01872851646d54432a203542c

URL: https://github.com/llvm/llvm-project/commit/000e790be35b77a01872851646d54432a203542c
DIFF: https://github.com/llvm/llvm-project/commit/000e790be35b77a01872851646d54432a203542c.diff

LOG: [lldb] Fixed IPv6 host formatting in #104238 (#111033)

This patch fixes the following problems
https://lab.llvm.org/buildbot/#/builders/162/builds/7720

Added: 
    

Modified: 
    lldb/tools/lldb-server/lldb-platform.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/tools/lldb-server/lldb-platform.cpp b/lldb/tools/lldb-server/lldb-platform.cpp
index d1f925685dff91..2ef780578d0a28 100644
--- a/lldb/tools/lldb-server/lldb-platform.cpp
+++ b/lldb/tools/lldb-server/lldb-platform.cpp
@@ -142,8 +142,8 @@ static Status parse_listen_host_port(Socket::SocketProtocol &protocol,
       return Status::FromErrorStringWithFormat(
           "The same platform and gdb ports %u.", platform_port);
     }
-    address = llvm::formatv("{0}:{1}", hostname, platform_port).str();
-    gdb_address = llvm::formatv("{0}:{1}", hostname, gdbserver_port).str();
+    address = llvm::formatv("[{0}]:{1}", hostname, platform_port).str();
+    gdb_address = llvm::formatv("[{0}]:{1}", hostname, gdbserver_port).str();
   } else {
     if (gdbserver_port) {
       return Status::FromErrorStringWithFormat(


        


More information about the lldb-commits mailing list