[Patch]reduce scim-bridge virtual memory usage.

2 messages Options
Embed this post
Permalink
Peng Wu

[Patch]reduce scim-bridge virtual memory usage.

Reply Threaded More More options
Print post
Permalink
Some javascript/style in this post has been disabled (why?)

Hi Ryo Dairiki,

   Recently I found that when scim-bridge initialize scim, it will load all imengines as the scim daemon does. In my opinion,  scim-bridge only need to use SocketIMEngine to connect the scim daemon. When two imengines in scim-bridge and scim access the same user data file, data corruption may occur.

    Here is a patch to load SocketIMengine instead of load all imengine. This patch will significantly reduce the virtual memory usage of scim-bridge.

    Best Wishes,

Peng Wu


Index: scim-bridge-0.4.15/agent/scim-bridge-agent.cpp
===================================================================
--- scim-bridge-0.4.15.orig/agent/scim-bridge-agent.cpp
+++ scim-bridge-0.4.15/agent/scim-bridge-agent.cpp
@@ -442,6 +442,9 @@ retval_t ScimBridgeAgentImpl::initialize
         return RETVAL_FAILED;
     }
 
+ imengine_module_names.clear();
+ imengine_module_names.push_back("socket");
+
     // Get config modules
     vector<String> config_module_names;
     scim_get_config_module_list (config_module_names);

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Scim-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/scim-devel
Ryo Dairiki-2

Re: [Patch]reduce scim-bridge virtual memory usage.

Reply Threaded More More options
Print post
Permalink
I've just imported it into svn repository, thanks.

Ryo

Peng Wu wrote:

>
> Hi Ryo Dairiki,
>
>    Recently I found that when scim-bridge initialize scim, it will
> load all imengines as the scim daemon does. In my opinion,
>  scim-bridge only need to use SocketIMEngine to connect the scim
> daemon. When two imengines in scim-bridge and scim access the same
> user data file, data corruption may occur.
>
>     Here is a patch to load SocketIMengine instead of load all
> imengine. This patch will significantly reduce the virtual memory
> usage of scim-bridge.
>
>     Best Wishes,
>
> Peng Wu
>
> ------------------------------------------------------------------------
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> ------------------------------------------------------------------------
>
> _______________________________________________
> Scim-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/scim-devel


------------------------------------------------------------------------------
_______________________________________________
Scim-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/scim-devel