Skip to content

Commit

Permalink
[lldb] Fix -Wformat warning in debugserver unit test
Browse files Browse the repository at this point in the history
RNBSocketTest.cpp:31:35: warning: format specifies type 'char *' but the
argument has type 'const void *' [-Wformat]
  • Loading branch information
JDevlieghere committed Dec 9, 2020
1 parent 846f576 commit c59ccc0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lldb/unittests/debugserver/RNBSocketTest.cpp
Expand Up @@ -28,7 +28,7 @@ static void ServerCallbackv4(const void *baton, in_port_t port) {
auto child_pid = fork();
if (child_pid == 0) {
char addr_buffer[256];
sprintf(addr_buffer, "%s:%d", baton, port);
sprintf(addr_buffer, "%s:%d", (const char *)baton, port);
llvm::Expected<std::unique_ptr<Socket>> socket_or_err =
Socket::TcpConnect(addr_buffer, false);
ASSERT_THAT_EXPECTED(socket_or_err, llvm::Succeeded());
Expand Down

0 comments on commit c59ccc0

Please sign in to comment.