mirror of
https://github.com/yuzu-emu/discord-rpc.git
synced 2024-11-24 05:55:43 +01:00
missed a format I guess
This commit is contained in:
parent
ef60ec40c3
commit
a6a9b6259f
@ -32,7 +32,6 @@ static const char* GetTempPath()
|
|||||||
|
|
||||||
/*static*/ BaseConnection* BaseConnection::Create()
|
/*static*/ BaseConnection* BaseConnection::Create()
|
||||||
{
|
{
|
||||||
|
|
||||||
PipeAddr.sun_family = AF_UNIX;
|
PipeAddr.sun_family = AF_UNIX;
|
||||||
return &Connection;
|
return &Connection;
|
||||||
}
|
}
|
||||||
@ -54,7 +53,8 @@ bool BaseConnection::Open()
|
|||||||
}
|
}
|
||||||
fcntl(self->sock, F_SETFL, O_NONBLOCK);
|
fcntl(self->sock, F_SETFL, O_NONBLOCK);
|
||||||
for (int pipeNum = 0; pipeNum < 10; ++pipeNum) {
|
for (int pipeNum = 0; pipeNum < 10; ++pipeNum) {
|
||||||
snprintf(PipeAddr.sun_path, sizeof(PipeAddr.sun_path), "%s/discord-ipc-%d", tempPath, pipeNum);
|
snprintf(
|
||||||
|
PipeAddr.sun_path, sizeof(PipeAddr.sun_path), "%s/discord-ipc-%d", tempPath, pipeNum);
|
||||||
int err = connect(self->sock, (const sockaddr*)&PipeAddr, sizeof(PipeAddr));
|
int err = connect(self->sock, (const sockaddr*)&PipeAddr, sizeof(PipeAddr));
|
||||||
if (err == 0) {
|
if (err == 0) {
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user