diff Core/HttpServer/HttpOutput.cpp @ 1592:d73124f6b439

configuration option HttpDescribeErrors
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 27 Aug 2015 11:35:16 +0200
parents 9c5d93510414
children 1558b3226b18
line wrap: on
line diff
--- a/Core/HttpServer/HttpOutput.cpp	Thu Aug 27 10:54:52 2015 +0200
+++ b/Core/HttpServer/HttpOutput.cpp	Thu Aug 27 11:35:16 2015 +0200
@@ -302,7 +302,15 @@
     
     stateMachine_.ClearHeaders();
     stateMachine_.SetHttpStatus(status);
-    stateMachine_.SendBody(message, messageSize);
+
+    if (describeErrors_)
+    {
+      stateMachine_.SendBody(message, messageSize);
+    }
+    else
+    {
+      stateMachine_.SendBody(NULL, 0);
+    }
   }