File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,12 @@ import 'logger.dart';
1414
1515const MIN_REGISTER_EXPIRES = 10 ; // In seconds.
1616
17+ class UnHandledResponse {
18+ var status_code;
19+ var reason_phrase;
20+ UnHandledResponse (this .status_code, this .reason_phrase);
21+ }
22+
1723class Registrator {
1824 UA _ua;
1925 Transport _transport;
@@ -127,11 +133,11 @@ class Registrator {
127133 EventManager localEventHandlers = EventManager ();
128134 localEventHandlers.on (EventOnRequestTimeout (),
129135 (EventOnRequestTimeout value) {
130- this ._registrationFailure (null , DartSIP_C .causes.REQUEST_TIMEOUT );
136+ this ._registrationFailure (UnHandledResponse ( 408 , DartSIP_C .causes. REQUEST_TIMEOUT ) , DartSIP_C .causes.REQUEST_TIMEOUT );
131137 });
132138 localEventHandlers.on (EventOnTransportError (),
133139 (EventOnTransportError value) {
134- this ._registrationFailure (null , DartSIP_C .causes.CONNECTION_ERROR );
140+ this ._registrationFailure (UnHandledResponse ( 500 , DartSIP_C .causes. CONNECTION_ERROR ) , DartSIP_C .causes.CONNECTION_ERROR );
135141 });
136142 localEventHandlers.on (EventOnAuthenticated (), (EventOnAuthenticated value) {
137143 this ._cseq += 1 ;
You can’t perform that action at this time.
0 commit comments