diff OrthancServer/Sources/EmbeddedResourceHttpHandler.cpp @ 5406:aaf7c49a9ddc am-http-compression

tentative to implement smart HTTP compression with detection of transfer syntax
author Alain Mazy <am@osimis.io>
date Sat, 04 Nov 2023 13:42:30 +0100
parents 0ea402b4d901
children
line wrap: on
line diff
--- a/OrthancServer/Sources/EmbeddedResourceHttpHandler.cpp	Tue Oct 17 15:06:11 2023 +0200
+++ b/OrthancServer/Sources/EmbeddedResourceHttpHandler.cpp	Sat Nov 04 13:42:30 2023 +0100
@@ -73,6 +73,7 @@
       size_t size = ServerResources::GetDirectoryResourceSize(resourceId_, resourcePath.c_str());
 
       output.SetContentType(contentType);
+      output.SetContentCompression(SystemToolbox::GuessContentCompression(contentType));
       output.Answer(buffer, size);
     }
     catch (OrthancException&)