Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
4e2e5abd
Commit
4e2e5abd
authored
Feb 04, 2018
by
DonLakeFlyer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Better logging for errors
parent
45d8d890
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
Terrain.cc
src/Terrain.cc
+3
-1
No files found.
src/Terrain.cc
View file @
4e2e5abd
...
...
@@ -112,13 +112,13 @@ void TerrainBatchManager::_batchFailed(void)
void
TerrainBatchManager
::
_requestFinished
()
{
qCDebug
(
ElevationProviderLog
)
<<
"_requestFinished"
;
QNetworkReply
*
reply
=
qobject_cast
<
QNetworkReply
*>
(
QObject
::
sender
());
_state
=
State
::
Idle
;
// When an error occurs we still end up here
if
(
reply
->
error
()
!=
QNetworkReply
::
NoError
)
{
qCDebug
(
ElevationProviderLog
)
<<
"_requestFinished error:"
<<
reply
->
error
();
_batchFailed
();
reply
->
deleteLater
();
return
;
...
...
@@ -129,6 +129,7 @@ void TerrainBatchManager::_requestFinished()
QJsonParseError
parseError
;
QJsonDocument
responseJson
=
QJsonDocument
::
fromJson
(
responseBytes
,
&
parseError
);
if
(
parseError
.
error
!=
QJsonParseError
::
NoError
)
{
qCDebug
(
ElevationProviderLog
)
<<
"_requestFinished unable to parse json:"
<<
parseError
.
errorString
();
_batchFailed
();
reply
->
deleteLater
();
return
;
...
...
@@ -137,6 +138,7 @@ void TerrainBatchManager::_requestFinished()
QJsonObject
rootObject
=
responseJson
.
object
();
QString
status
=
rootObject
[
"status"
].
toString
();
if
(
status
!=
"success"
)
{
qCDebug
(
ElevationProviderLog
)
<<
"_requestFinished status != success:"
<<
status
;
_batchFailed
();
reply
->
deleteLater
();
return
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment