Bug 205699

Summary: connection between scim and application stops randomly
Product: [Fedora] Fedora Reporter: Lawrence Lim <llim>
Component: scim-bridgeAssignee: Jens Petersen <petersen>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: eng-i18n-bugs, ryo-dairiki, tools-bugs
Target Milestone: ---Keywords: i18n
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-10-18 08:09:01 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 167798    

Description Lawrence Lim 2006-09-08 00:24:48 UTC
Description of problem:
As discussed, it is prolly best to submit a bug to gain wider exposure.

This symptom has been noticed a while ago and confirmed during QA Event, where a
number of users has noticed this bug on numerous occassion.

Version-Release number of selected component (if applicable):
before scim-1.4.4-34.fc6 
scim-bridge-0.4.2-1.fc6

How reproducible:
Not 100%

Steps to Reproduce:
1.normal usage of IM over a period of time on Gtk Apps
2.
3.
  
Actual results:
Connection between scim and apps gets cut off, as a result, no IME available.
Select IME from scim icon on systray will re-establish the connection again.

Expected results:
Connection should be persistant

Additional info:
The frequency is much higher on vnc, Jens had seen it once. ;-)

Comment 1 Ryo Dairiki 2006-09-10 13:06:14 UTC
That time, is the agent down?
If it's down, what error is shown in dsmg?
Please move into a virtual terminal and check it.

Comment 2 Lawrence Lim 2006-09-11 00:12:14 UTC
Thanks for the tips Ryo-san. I will watch out for these error message. 

Comment 3 Ryo Dairiki 2006-09-11 15:43:02 UTC
Btw, you can get the corefile if the agent is crashed.
It will help us to solve this problem. :)

1. Make a shell script "scim-bridge" as follows:

#!/usr/bin/bash

ulimic -c unlimited
exec /usr/bin/scim-bridge

2. Install the script into /usr/local/bin/

3. Patch "scim-bridge-agent.cpp" as follows and make install it:

retval_t ScimBridgeAgentImpl::launch ()
{
    scim_bridge_pdebugln (5, "launch ()");
...
        } else {
            // This is the child process.
-            if (chdir ("/")) {
+            if (chdir ("/tmp")) {
                scim_bridge_perrorln ("Cannot change the working directory: %s",
strerror (errno));
                return RETVAL_FAILED;
            }
            close (0);
            close (1);
            close (2);
        }

        scim_bridge_pdebugln (5, "Daemonize done");
...
}

4. Logout once, and relogin.

5. Wait until the agent crashes.

Comment 4 Jens Petersen 2006-09-18 09:35:42 UTC
Is this any better with scim-bridge-0.4.5?

Comment 5 Jens Petersen 2006-10-18 08:09:01 UTC
Closing for now.  Please reopen if you still see this.