[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-solaris
Subject:    Re: [kde-solaris] dcopserver statup problem and /tmp/.ICE-unix
From:       Alexander_Velásquez <avelasqu () euler ! ciens ! ucv ! ve>
Date:       2006-03-06 13:40:34
Message-ID: 161301c64123$8cbfaaf0$c145b996 () klein
[Download RAW message or body]

Thanks a lot Stefan!

This script fixed the problem in my system due to this issue on KDE ...

----- Original Message ----- 
From: "Stefan Teleman" <steleman@nyc.rr.com>
To: "KDE Solaris" <kde-solaris@mail.kde.org>
Sent: Saturday, February 11, 2006 9:09 PM
Subject: Re: [kde-solaris] dcopserver statup problem and /tmp/.ICE-unix


> On Saturday 11 February 2006 19:49, Avi Schwartz wrote:
> > > Is this a Blastwave related question ?
> >
> > It is a KDE related question.  The build is the Blastwave build.
> 
> And the build doesn't handle this particular problem correctly, which 
> a known problem, and has been known for years.
> 
> There are three directories under /tmp which need to have their 
> permissions set correctly by the startup script:
> 
> /tmp/.ICE-unix
> /tmp/.X11-unix
> /tmp/.X11-pipe
> 
> /* kchmod.c */
> 
> #include <stdio.h>
> #include <stdlib.h>
> #include <string.h>
> #include <sys/types.h>
> #include <sys/stat.h>
> #include <unistd.h>
> #include <errno.h>
> 
> static const char* unixPath = "/tmp/.X11-unix";
> static const char* pipePath = "/tmp/.X11-pipe";
> static const char* icePath = "/tmp/.ICE-unix";
> static const char* fontPath = "/tmp/.font-unix";
> extern int errno;
> 
> int
> main (int argc, char* argv[])
> {
>     mode_t mode = 0;
>     uid_t uid = 0;
>     gid_t gid = 0;
> 
>     mode = (S_IRWXU | S_IRWXG | S_IRWXO | S_ISVTX);
> 
>     if (setuid (uid) != 0)
>     {
>       perror ("setuid"), strerror (errno);
>       return -1;
>     }
>     if (mkdir (unixPath, mode) != 0)
>     {
>       if (EEXIST != errno)
>       {
>         perror("mkdir"), strerror(errno);
>         return -2;
>       }
>     }
>     if (chmod (unixPath, mode) != 0)
>       perror ("chmod"), strerror (errno);
> 
>     if (chown (unixPath, uid, gid) != 0)
>       perror ("chown"), strerror (errno);
> 
>     if (mkdir (pipePath, mode) != 0)
>     {
>       if (EEXIST != errno)
>       {
>         perror("mkdir"), strerror(errno);
>         return -2;
>       }
>     }
>     if (chmod (pipePath, mode) != 0)
>       perror ("chmod"), strerror (errno);
> 
>     if (chown (pipePath, uid, gid) != 0)
>       perror ("chown"), strerror (errno);
> 
>     if (mkdir (icePath, mode) != 0)
>     {
>       if (EEXIST != errno)
>       {
>         perror("mkdir"), strerror(errno);
>         return -2;
>       }
>     }
>     if (chmod (icePath, mode) != 0)
>       perror ("chmod"), strerror (errno);
> 
>     if (chown (icePath, uid, gid) != 0)
>       perror ("chown"), strerror (errno);
> 
>     if (mkdir (fontPath, mode) != 0)
>     {
>       if (EEXIST != errno)
>       {
>         perror("mkdir"), strerror(errno);
>         return -2;
>       }
>     }
>     if (chmod (fontPath, mode) != 0)
>       perror ("chmod"), strerror (errno);
> 
>     if (chown (fontPath, uid, gid) != 0)
>       perror ("chown"), strerror (errno);
> 
>     return 0;
> }
> 
> // vim: ts=2 sw=2 et
> 
> /* kchmod.c */
> 
> Compile and install as ${KDE}/bin/kchmod, permissions 4755, owned 
> root:root and run it directly from startkde, somewhere near the top 
> before anything KDE-related starts happening.
> 
> Do not keep deleting these directories because that will not fix 
> anything.
> 
> --Stefan
> 
> -- 
> Stefan Teleman          'Nobody Expects the Spanish Inquisition'
> steleman@nyc.rr.com                          -Monty Python
> ___________________________________________________
> This message is from the kde-solaris mailing list.
> Account management:  https://mail.kde.org/mailman/listinfo/kde-solaris.
> Archives: http://lists.kde.org/.
> More info: http://www.kde.org/faq.html.
___________________________________________________
This message is from the kde-solaris mailing list.
Account management:  https://mail.kde.org/mailman/listinfo/kde-solaris.
Archives: http://lists.kde.org/.
More info: http://www.kde.org/faq.html.
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic