mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-24 21:39:55 +00:00
make unix domain socket 'public'
This commit is contained in:
parent
4f3229d8d2
commit
1bf2f2d290
@ -63,6 +63,8 @@
|
||||
#include <sys/un.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include <sys/stat.h>
|
||||
|
||||
#ifdef USE_LAUNCHD
|
||||
#include "../3rdparty/launch.h"
|
||||
#endif
|
||||
@ -476,7 +478,12 @@ int socket_connection_create_unix(char *path){
|
||||
free(ds);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
// http://blog.henning.makholm.net/2008/06/unix-domain-socket-woes.html
|
||||
// make socket accept from all clients
|
||||
chmod(path, S_IRWXU | S_IRWXG | S_IRWXO);
|
||||
//
|
||||
|
||||
if (listen (ds->fd, MAX_PENDING_CONNECTIONS)) {
|
||||
log_error( "Error on listen() ...(%s)\n", strerror(errno));
|
||||
free(ds);
|
||||
|
Loading…
x
Reference in New Issue
Block a user