https://bugs.kde.org/show_bug.cgi?id=435113

--- Comment #87 from Chris <ch...@loggytronic.com> ---
Once again, apologies if I'm hijacking the thread, but I think I'm getting
somewhere here. If we're lucky, it's something to do with this bug.

With this intercept program placed at /usr/bin/kcminit ...

#include <unistd.h>
#include <stdlib.h>

void main(int argc, char** argv)
{
  system("ps auxf > /tmp/kcminit.log");
  execv("/usr/bin/kcminit-real", argv);
}


... I am proving that when I hotplug a mouse something executes kcminit to
configure it, because in my kcminit.log this turns up:

USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
chris       2579  0.0  0.0   2772  1344 ?        S    22:31   0:00
/usr/bin/kcminit mouse
chris       2580  0.0  0.0   2888   948 ?        S    22:31   0:00  \_ sh -c ps
auxf > /tmp/kcminit.log
chris       2581  0.0  0.0   7816  3512 ?        R    22:31   0:00      \_ ps
auxf

Note that the call is kcminit mouse, not kcminit kcm_mouse as it should be.

So I think there are two problems here, Firstly the so files have moved and
kcminit is looking in the wrong place for them. Secondly, whatever is calling
kcminit is calling it with "mouse" and not "kcm_mouse".

Modifying the intercept program to this:

#include <unistd.h>
#include <stdlib.h>
#include <string.h>

void main(int argc, char** argv)
{
  system("ps auxf > /tmp/kcminit.log");
  if (!strcmp(argv[1], "mouse")) argv[1] = "kcm_mouse";
  execv("/usr/bin/kcminit-real", argv);
}


... fixes my system. (Where "fix" = absolute bodge hack).

Obviously to fix it properly would need whatever is calling kcminit to be
modified, and the so file situation sorted out. I can't tell what is executing
kcminit as it appears at the root level of the ps "forest".

Anyone want to dare to test this on your system?

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to