From a97fa3f43e313848ba6b4cd65840ba8c60ac485f Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Thu, 22 May 2008 12:59:42 +0000 Subject: changing more 'raw' HTTP status codes to OSHttpStatusCodes. --- OpenSim/Framework/Servers/OSHttpStatusCodes.cs | 2 ++ .../Environment/Modules/Scripting/HttpRequest/ScriptsHttpRequests.cs | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Framework/Servers/OSHttpStatusCodes.cs b/OpenSim/Framework/Servers/OSHttpStatusCodes.cs index 2e001cf..9a04d82 100644 --- a/OpenSim/Framework/Servers/OSHttpStatusCodes.cs +++ b/OpenSim/Framework/Servers/OSHttpStatusCodes.cs @@ -138,6 +138,8 @@ namespace OpenSim.Framework.Servers // expressed in one or more Expect header fields cannot be met // by the server, the server is awfully sorry about this. ClientErrorExpectationFailed = 417, + // 499 Client error: Wildcard error. + ClientErrorJoker = 499, // 5xx Server errors (rare) // 500 Server error: something really strange and unexpected diff --git a/OpenSim/Region/Environment/Modules/Scripting/HttpRequest/ScriptsHttpRequests.cs b/OpenSim/Region/Environment/Modules/Scripting/HttpRequest/ScriptsHttpRequests.cs index 87ecfee..e0d5972 100644 --- a/OpenSim/Region/Environment/Modules/Scripting/HttpRequest/ScriptsHttpRequests.cs +++ b/OpenSim/Region/Environment/Modules/Scripting/HttpRequest/ScriptsHttpRequests.cs @@ -34,6 +34,7 @@ using System.Threading; using libsecondlife; using Nini.Config; using OpenSim.Framework; +using OpenSim.Framework.Servers; using OpenSim.Region.Environment.Interfaces; using OpenSim.Region.Environment.Scenes; @@ -340,13 +341,13 @@ namespace OpenSim.Region.Environment.Modules.Scripting.HttpRequest } catch (Exception e) { - status = 499; + status = (int)OSHttpStatusCode.ClientErrorJoker; response_body = e.Message; finished = true; return; } - status = 200; + status = (int)OSHttpStatusCode.SuccessOk; finished = true; } -- cgit v1.1