mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-11 07:22:22 +00:00
634cfceb32
privilege to the unix domain socket from group and others. This should be no user-visible change.
35 lines
1.1 KiB
C
35 lines
1.1 KiB
C
--- lib/IMProto.c.orig 2002-10-03 18:35:28.000000000 +0900
|
|
+++ lib/IMProto.c 2008-11-08 16:03:58.000000000 +0900
|
|
@@ -259,7 +259,7 @@
|
|
#ifdef IM_TCP_TRANSPORT
|
|
if (ipw->imp.use_tcp_transport) {
|
|
ipw->imp.tcp_port = 0; /* let the system choose the port number */
|
|
- ipw->imp.tcp_sock = IMCreateTCPService(&ipw->imp.tcp_port);
|
|
+ ipw->imp.tcp_sock = IMCreateTCPService(&ipw->imp.tcp_port, "localhost");
|
|
}
|
|
if (ipw->imp.tcp_sock >= 0) {
|
|
TRACE(("call XtAppAddInput for tcp socket(%d)\n", ipw->imp.tcp_sock));
|
|
@@ -281,7 +281,7 @@
|
|
* The unix domain socket pathname has the following form:
|
|
* <UNIX_SOCKET_DIR>/<Display Name>-<Language>
|
|
*/
|
|
- (void)mkdir(UNIX_SOCKET_DIR, 0777);
|
|
+ (void)mkdir(UNIX_SOCKET_DIR, 01777);
|
|
#ifdef S_IFLNK
|
|
{
|
|
/*
|
|
@@ -292,11 +292,11 @@
|
|
struct stat st;
|
|
if (lstat(UNIX_SOCKET_DIR, &st) == 0 &&
|
|
(st.st_mode & S_IFMT) == S_IFDIR) {
|
|
- (void)chmod(UNIX_SOCKET_DIR, 0777);
|
|
+ (void)chmod(UNIX_SOCKET_DIR, 01777);
|
|
}
|
|
}
|
|
#else
|
|
- (void)chmod(UNIX_SOCKET_DIR, 0777);
|
|
+ (void)chmod(UNIX_SOCKET_DIR, 01777);
|
|
#endif
|
|
(void)sprintf(path, "%s/%s", UNIX_SOCKET_DIR,
|
|
DisplayString(XtDisplay(new)));
|