summaryrefslogtreecommitdiff
path: root/indra/llcorehttp/httpcommon.h
diff options
context:
space:
mode:
authorMonty Brandenberg <monty@lindenlab.com>2013-05-06 12:12:05 -0400
committerMonty Brandenberg <monty@lindenlab.com>2013-05-06 12:12:05 -0400
commitf5e8457e4e4fad1d823c51d86c01fdc2ae08401c (patch)
treef74cba7085bc46ca4f71a6a5c083cfda876c01f5 /indra/llcorehttp/httpcommon.h
parentf9850aa5d2fbed3e039ac1a1015ff73065664f17 (diff)
BUG-2295/MAINT-2624 unexpected crash around Content-Range: header processing
Not certain what the source of the short data is with one resident but I'm going to make these problems retryable as they are transport-related. Lift the retry detection into a method that should be reusable by others interested in determining what is retryable. Trace output handling on the libcurl debug callback was attrocious. Some unsafe length handling on my part was protected by a second layer of defense. Made that correct and more useful by logging actual data sizes during trace.
Diffstat (limited to 'indra/llcorehttp/httpcommon.h')
-rw-r--r--indra/llcorehttp/httpcommon.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/indra/llcorehttp/httpcommon.h b/indra/llcorehttp/httpcommon.h
index c0d4ec5aad..41fb5164cf 100644
--- a/indra/llcorehttp/httpcommon.h
+++ b/indra/llcorehttp/httpcommon.h
@@ -4,7 +4,7 @@
*
* $LicenseInfo:firstyear=2012&license=viewerlgpl$
* Second Life Viewer Source Code
- * Copyright (C) 2012, Linden Research, Inc.
+ * Copyright (C) 2012-2013, Linden Research, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -303,6 +303,12 @@ struct HttpStatus
{
return mType >= type_enum_t(100) && mType <= type_enum_t(999);
}
+
+ /// Returns true if the status is one that will be retried
+ /// internally. Provided for external consumption for cases
+ /// where that logic needs to be replicated. Only applies
+ /// to failed statuses, successful statuses will return false.
+ bool isRetryable() const;
}; // end struct HttpStatus