Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dap-ui-sdk
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
7
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dap
dap-ui-sdk
Commits
eab3af36
Commit
eab3af36
authored
4 years ago
by
Danil Martynenko
Browse files
Options
Downloads
Patches
Plain Diff
[*]
parent
9f69bc52
No related branches found
No related tags found
1 merge request
!208
bugs-4298 [*] Fixed system for receiving and processing errors
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
core/DapServersListRequester.h
+5
-0
5 additions, 0 deletions
core/DapServersListRequester.h
core/DapSession.cpp
+2
-3
2 additions, 3 deletions
core/DapSession.cpp
vpn/client/DapCmdHandlers/DapCmdServersList.cpp
+1
-1
1 addition, 1 deletion
vpn/client/DapCmdHandlers/DapCmdServersList.cpp
with
8 additions
and
4 deletions
core/DapServersListRequester.h
+
5
−
0
View file @
eab3af36
...
...
@@ -20,6 +20,11 @@ public:
}
return
reply
->
errorString
();
}
QNetworkReply
::
NetworkError
networkReplyError
(){
return
qobject_cast
<
QNetworkReply
*>
(
parent
())
->
error
();
}
signals
:
void
sigResponse
(
const
QJsonDocument
&
doc
);
void
sigNetworkError
(
QNetworkReply
::
NetworkError
);
...
...
This diff is collapsed.
Click to expand it.
core/DapSession.cpp
+
2
−
3
View file @
eab3af36
...
...
@@ -206,10 +206,9 @@ void DapSession::onEnc()
if
(
m_netEncryptReply
&&
(
m_netEncryptReply
->
error
()
!=
QNetworkReply
::
NoError
))
{
qCritical
()
<<
"Network error: "
<<
m_netEncryptReply
->
errorString
();
if
(
m_netEncryptReply
->
error
()
==
QNetworkReply
::
OperationCanceledError
)
if
(
m_netEncryptReply
->
error
()
==
QNetworkReply
::
OperationCanceledError
||
m_netEncryptReply
->
error
()
==
QNetworkReply
::
ConnectionRefusedError
)
emit
errorNetwork
(
6543
,
m_netEncryptReply
->
errorString
());
else
if
(
m_netEncryptReply
->
error
()
==
QNetworkReply
::
Network
SessionFailed
Error
)
else
if
(
m_netEncryptReply
->
error
()
==
QNetworkReply
::
Unknown
NetworkError
)
emit
errorNetwork
(
3244
,
m_netEncryptReply
->
errorString
());
else
emit
errorNetwork
(
m_netEncryptReply
->
errorString
());
...
...
This diff is collapsed.
Click to expand it.
vpn/client/DapCmdHandlers/DapCmdServersList.cpp
+
1
−
1
View file @
eab3af36
...
...
@@ -42,7 +42,7 @@ void DapCmdServersList::handle(const QJsonObject* params)
connect
(
reply
,
&
DapServersListNetworkReply
::
sigNetworkError
,
[
=
]{
qWarning
()
<<
"Network error: "
<<
reply
->
errorString
();
rotateList
();
if
(
reply
->
errorString
()
==
"Network unreachable"
||
r
eply
->
e
rror
String
()
==
"
Network
access is disabled."
)
if
(
reply
->
networkR
eply
E
rror
()
==
Q
Network
Reply
::
UnknownNetworkError
)
sendSimpleError
(
-
32003
,
reply
->
errorString
());
else
sendSimpleError
(
-
32002
,
reply
->
errorString
());
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment