From f79713e504c6be6023533d67c25b5846e3588f8d Mon Sep 17 00:00:00 2001 From: trialuser02 Date: Sat, 3 Jul 2010 06:23:01 +0000 Subject: fixed problem with UDS under freebsd (patch by SimaMoto,RyoTa) git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@1792 90c681e8-e032-0410-971d-27865f9a5e38 --- src/ui/unixdomainsocket.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/ui/unixdomainsocket.cpp b/src/ui/unixdomainsocket.cpp index 0801ef6db..6680c457b 100644 --- a/src/ui/unixdomainsocket.cpp +++ b/src/ui/unixdomainsocket.cpp @@ -46,10 +46,10 @@ bool UnixDomainSocket::bind(const QString& path){ bzero(&_local,sizeof(_local)); _local.sun_family = AF_UNIX; strcpy(_local.sun_path,path.toLocal8Bit().data()); - len = strlen(_local.sun_path) + sizeof(_local.sun_family); + len = strlen(_local.sun_path) + sizeof(_local.sun_family) + 1; bool res = !(::bind(_s, (struct sockaddr *)&_local, len)); if(res) - _bound = true; + _bound = true; return res; } -- cgit v1.2.3-13-gbd6f