Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Alchemy Viewer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
Alchemy Viewer
Alchemy Viewer
Commits
e7a1e619
Commit
e7a1e619
authored
10 years ago
by
Rider Linden
Browse files
Options
Downloads
Patches
Plain Diff
Slightly cleaner than this-> ing everythnig.
parent
530bf560
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
indra/llcorehttp/httpcommon.cpp
+11
-11
11 additions, 11 deletions
indra/llcorehttp/httpcommon.cpp
with
11 additions
and
11 deletions
indra/llcorehttp/httpcommon.cpp
+
11
−
11
View file @
e7a1e619
...
@@ -131,18 +131,18 @@ std::string HttpStatus::toString() const
...
@@ -131,18 +131,18 @@ std::string HttpStatus::toString() const
{
{
return
std
::
string
(
""
);
return
std
::
string
(
""
);
}
}
switch
(
this
->
mDetails
->
m
Type
)
switch
(
get
Type
()
)
{
{
case
EXT_CURL_EASY
:
case
EXT_CURL_EASY
:
return
std
::
string
(
curl_easy_strerror
(
CURLcode
(
this
->
mDetails
->
m
Status
)));
return
std
::
string
(
curl_easy_strerror
(
CURLcode
(
get
Status
()
)));
case
EXT_CURL_MULTI
:
case
EXT_CURL_MULTI
:
return
std
::
string
(
curl_multi_strerror
(
CURLMcode
(
this
->
mDetails
->
m
Status
)));
return
std
::
string
(
curl_multi_strerror
(
CURLMcode
(
get
Status
()
)));
case
LLCORE
:
case
LLCORE
:
if
(
this
->
mDetails
->
m
Status
>=
0
&&
this
->
mDetails
->
m
Status
<
llcore_errors_count
)
if
(
get
Status
()
>=
0
&&
get
Status
()
<
llcore_errors_count
)
{
{
return
std
::
string
(
llcore_errors
[
this
->
mDetails
->
m
Status
]);
return
std
::
string
(
llcore_errors
[
get
Status
()
]);
}
}
break
;
break
;
...
@@ -154,7 +154,7 @@ std::string HttpStatus::toString() const
...
@@ -154,7 +154,7 @@ std::string HttpStatus::toString() const
while
(
true
)
while
(
true
)
{
{
int
at
((
bottom
+
top
)
/
2
);
int
at
((
bottom
+
top
)
/
2
);
if
(
this
->
mDetails
->
m
Type
==
http_errors
[
at
].
mCode
)
if
(
get
Type
()
==
http_errors
[
at
].
mCode
)
{
{
return
std
::
string
(
http_errors
[
at
].
mText
);
return
std
::
string
(
http_errors
[
at
].
mText
);
}
}
...
@@ -162,7 +162,7 @@ std::string HttpStatus::toString() const
...
@@ -162,7 +162,7 @@ std::string HttpStatus::toString() const
{
{
break
;
break
;
}
}
else
if
(
this
->
mDetails
->
m
Type
<
http_errors
[
at
].
mCode
)
else
if
(
get
Type
()
<
http_errors
[
at
].
mCode
)
{
{
top
=
at
;
top
=
at
;
}
}
...
@@ -182,9 +182,9 @@ std::string HttpStatus::toTerseString() const
...
@@ -182,9 +182,9 @@ std::string HttpStatus::toTerseString() const
{
{
std
::
ostringstream
result
;
std
::
ostringstream
result
;
unsigned
int
error_value
((
unsigned
short
)
(
this
->
mDetails
->
m
Status
));
unsigned
int
error_value
((
unsigned
short
)
get
Status
(
));
switch
(
this
->
mDetails
->
m
Type
)
switch
(
get
Type
()
)
{
{
case
EXT_CURL_EASY
:
case
EXT_CURL_EASY
:
result
<<
"Easy_"
;
result
<<
"Easy_"
;
...
@@ -202,7 +202,7 @@ std::string HttpStatus::toTerseString() const
...
@@ -202,7 +202,7 @@ std::string HttpStatus::toTerseString() const
if
(
isHttpStatus
())
if
(
isHttpStatus
())
{
{
result
<<
"Http_"
;
result
<<
"Http_"
;
error_value
=
this
->
mDetails
->
m
Type
;
error_value
=
get
Type
()
;
}
}
else
else
{
{
...
@@ -244,7 +244,7 @@ bool HttpStatus::isRetryable() const
...
@@ -244,7 +244,7 @@ bool HttpStatus::isRetryable() const
// Disable the '*this == inv_status' test and look for 'Core_9'
// Disable the '*this == inv_status' test and look for 'Core_9'
// failures in log files.
// failures in log files.
return
((
isHttpStatus
()
&&
this
->
mDetails
->
m
Type
>=
499
&&
this
->
mDetails
->
m
Type
<=
599
)
||
// Include special 499 in retryables
return
((
isHttpStatus
()
&&
get
Type
()
>=
499
&&
get
Type
()
<=
599
)
||
// Include special 499 in retryables
*
this
==
cant_connect
||
// Connection reset/endpoint problems
*
this
==
cant_connect
||
// Connection reset/endpoint problems
*
this
==
cant_res_proxy
||
// DNS problems
*
this
==
cant_res_proxy
||
// DNS problems
*
this
==
cant_res_host
||
// DNS problems
*
this
==
cant_res_host
||
// DNS problems
...
...
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