yuanjianjiang / imsdroid

Automatically exported from code.google.com/p/imsdroid
0 stars 0 forks source link

NgnConfigurationEntry.QOS_SIP_CALLS_TIMEOUT does not work in NgnAVSession.java #475

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
a) Before posting your issue you MUST answer to the questions otherwise it
will be rejected (invalid status) by us
b) Please check the issue tacker to avoid duplication
c) Please provide network capture (wireshark) or Android log (DDMS output)
if you want quick response

What steps will reproduce the problem?
1.check the log via log cat
2.
3.

What is the expected output? What do you see instead?
In ScreenQoS.java, NgnConfigurationEntry.QOS_SIP_CALLS_TIMEOUT config-item is 
get/set as String.
But in NgnAVSession.java it is accessed via mConfigurationService.getInt(). 
This will throw Exception.
Suggest to refine ScreenQoS.java as below:
            long timeout = NgnConfigurationEntry.DEFAULT_QOS_SIP_CALLS_TIMEOUT;

            String timeoutStr = mConfigurationService.getString( NgnConfigurationEntry.QOS_SIP_CALLS_TIMEOUT, String.valueOf(NgnConfigurationEntry.DEFAULT_QOS_SIP_CALLS_TIMEOUT));
            try {
                timeout = Long.valueOf(timeoutStr).longValue();
            } catch(Throwable ex) {
                ex.printStackTrace();
            }
            mSession.setSessionTimer(timeout,
                    mConfigurationService.getString(NgnConfigurationEntry.QOS_REFRESHER,
                            NgnConfigurationEntry.DEFAULT_QOS_REFRESHER));

What version of the product are you using? On what operating system?

Please provide any additional information below.

Original issue reported on code.google.com by gumin...@gmail.com on 21 Aug 2013 at 1:25