Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(4482)

Issue 4670044: Use ibus_config_get_values () to improve performance. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years, 10 months ago by Peng
Modified:
12 years, 9 months ago
Reviewers:
Yusuke Sato
CC:
bryeung
Base URL:
git@github.com:ibus/ibus-pinyin.git@master
Visibility:
Public.

Description

Use ibus_config_get_values () to improve performance. BUG=http://crosbug.com/16287 TEST=Linux desktop

Patch Set 1 #

Total comments: 6

Patch Set 2 : update #

Unified diffs Side-by-side diffs Delta from patch set Stats (+158 lines, -90 lines) Patch
M configure.ac View 1 chunk +10 lines, -0 lines 0 comments Download
M src/PYConfig.h View 3 chunks +6 lines, -2 lines 0 comments Download
M src/PYConfig.cc View 1 21 chunks +142 lines, -88 lines 0 comments Download

Messages

Total messages: 4
Peng
12 years, 10 months ago (2011-07-04 19:00:20 UTC) #1
Yusuke Sato
http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc File src/PYConfig.cc (right): http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc#newcode163 src/PYConfig.cc:163: ibus_config_get_values (get<IBusConfig> (), m_section.c_str ()); to prevent null ptr ...
12 years, 9 months ago (2011-07-05 05:31:44 UTC) #2
Peng
http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc File src/PYConfig.cc (right): http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc#newcode163 src/PYConfig.cc:163: ibus_config_get_values (get<IBusConfig> (), m_section.c_str ()); On 2011/07/05 05:31:44, Yusuke ...
12 years, 9 months ago (2011-07-05 15:00:08 UTC) #3
Yusuke Sato
12 years, 9 months ago (2011-07-05 15:38:04 UTC) #4
On 2011/07/05 15:00:08, Peng wrote:
> http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc
> File src/PYConfig.cc (right):
> 
> http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc#newcode163
> src/PYConfig.cc:163: ibus_config_get_values (get<IBusConfig> (),
m_section.c_str
> ());
> On 2011/07/05 05:31:44, Yusuke Sato wrote:
> > to prevent null ptr deref, please check the return value of the
> > ibus_config_get_values function.
> 
> Done.
> 
> http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc#newcode275
> src/PYConfig.cc:275: normalizeGVariant (GVariant *value, const gchar * defval)
> On 2011/07/05 05:31:44, Yusuke Sato wrote:
> > overloading functions with bool, gint and const gchar* looks scary to me
(e.g.
> > which function will actually be called by normalizeGVariant(v, 0)?).
> > 
> > how about changing the last one to const std::string& ?
> 
> Done.
> 
> http://codereview.appspot.com/4670044/diff/1/src/PYConfig.cc#newcode308
> src/PYConfig.cc:308: if (normalizeGVariant (value, TRUE))
> On 2011/07/05 05:31:44, Yusuke Sato wrote:
> > question: is the correct function (i.e. the first one) called? I guess
not...
> 
> Done.


lgtm
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b