diff options
Diffstat (limited to 'OpenSim/Framework/WebUtil.cs')
-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 55b38cd..4b69468 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) |
@@ -930,11 +930,18 @@ namespace OpenSim.Framework | |||
930 | /// the request. You'll want to make sure you deal with this as they're not uncommon</exception> | 930 | /// the request. You'll want to make sure you deal with this as they're not uncommon</exception> |
931 | public static TResponse MakeRequest<TRequest, TResponse>(string verb, string requestUrl, TRequest obj) | 931 | public static TResponse MakeRequest<TRequest, TResponse>(string verb, string requestUrl, TRequest obj) |
932 | { | 932 | { |
933 | return MakeRequest<TRequest, TResponse>(verb, requestUrl, obj, 0); | ||
934 | } | ||
935 | |||
936 | public static TResponse MakeRequest<TRequest, TResponse>(string verb, string requestUrl, TRequest obj, int pTimeout) | ||
937 | { | ||
933 | Type type = typeof(TRequest); | 938 | Type type = typeof(TRequest); |
934 | TResponse deserial = default(TResponse); | 939 | TResponse deserial = default(TResponse); |
935 | 940 | ||
936 | WebRequest request = WebRequest.Create(requestUrl); | 941 | WebRequest request = WebRequest.Create(requestUrl); |
937 | request.Method = verb; | 942 | request.Method = verb; |
943 | if (pTimeout != 0) | ||
944 | request.Timeout = pTimeout * 1000; | ||
938 | 945 | ||
939 | if ((verb == "POST") || (verb == "PUT")) | 946 | if ((verb == "POST") || (verb == "PUT")) |
940 | { | 947 | { |