Browse Source

Correct JackServerSocket::Bind.

tags/v1.9.10
Stephane Letz 12 years ago
parent
commit
3e63ef6ebb
1 changed files with 4 additions and 2 deletions
  1. +4
    -2
      posix/JackSocket.cpp

+ 4
- 2
posix/JackSocket.cpp View File

@@ -253,8 +253,10 @@ int JackServerSocket::Bind(const char* dir, const char* name, int which) // A re
}

addr.sun_family = AF_UNIX;
BuildName(name, addr.sun_path, dir, which, sizeof(addr.sun_path));
// Socket name has to be kept in fName to be "unlinked".
BuildName(name, fName, dir, which, sizeof(addr.sun_path));
strncpy(addr.sun_path, fName, sizeof(addr.sun_path) - 1);
jack_log("JackServerSocket::Bind : addr.sun_path %s", addr.sun_path);
unlink(fName); // Security...



Loading…
Cancel
Save