diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Framework/WebUtil.cs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/OpenSim/Framework/WebUtil.cs b/OpenSim/Framework/WebUtil.cs index 147a011..f176485 100644 --- a/OpenSim/Framework/WebUtil.cs +++ b/OpenSim/Framework/WebUtil.cs | |||
@@ -311,7 +311,7 @@ namespace OpenSim.Framework | |||
311 | /// </summary> | 311 | /// </summary> |
312 | public static OSDMap PostToService(string url, NameValueCollection data) | 312 | public static OSDMap PostToService(string url, NameValueCollection data) |
313 | { | 313 | { |
314 | return ServiceFormRequest(url,data,10000); | 314 | return ServiceFormRequest(url,data, 20000); |
315 | } | 315 | } |
316 | 316 | ||
317 | public static OSDMap ServiceFormRequest(string url, NameValueCollection data, int timeout) | 317 | public static OSDMap ServiceFormRequest(string url, NameValueCollection data, int timeout) |
@@ -934,11 +934,18 @@ namespace OpenSim.Framework | |||
934 | /// the request. You'll want to make sure you deal with this as they're not uncommon</exception> | 934 | /// the request. You'll want to make sure you deal with this as they're not uncommon</exception> |
935 | public static TResponse MakeRequest<TRequest, TResponse>(string verb, string requestUrl, TRequest obj) | 935 | public static TResponse MakeRequest<TRequest, TResponse>(string verb, string requestUrl, TRequest obj) |
936 | { | 936 | { |
937 | return MakeRequest<TRequest, TResponse>(verb, requestUrl, obj, 0); | ||
938 | } | ||
939 | |||
940 | public static TResponse MakeRequest<TRequest, TResponse>(string verb, string requestUrl, TRequest obj, int pTimeout) | ||
941 | { | ||
937 | Type type = typeof(TRequest); | 942 | Type type = typeof(TRequest); |
938 | TResponse deserial = default(TResponse); | 943 | TResponse deserial = default(TResponse); |
939 | 944 | ||
940 | WebRequest request = WebRequest.Create(requestUrl); | 945 | WebRequest request = WebRequest.Create(requestUrl); |
941 | request.Method = verb; | 946 | request.Method = verb; |
947 | if (pTimeout != 0) | ||
948 | request.Timeout = pTimeout * 1000; | ||
942 | 949 | ||
943 | if ((verb == "POST") || (verb == "PUT")) | 950 | if ((verb == "POST") || (verb == "PUT")) |
944 | { | 951 | { |