File tree Expand file tree Collapse file tree 2 files changed +7
-0
lines changed
profiler/test/Datadog.Profiler.IntegrationTests Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change 8686 <IncludeAssets >runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets >
8787 <PrivateAssets >all</PrivateAssets >
8888 </PackageReference >
89+ <PackageReference Include =" ZstdSharp.Port" Version =" 0.8.6" />
8990 </ItemGroup >
9091 <ItemGroup Condition =" $(DD_LOGGER_ENABLED) != 'false' " >
9192 <PackageReference Include =" DatadogTestLogger" Version =" 0.0.38" ExcludeAssets =" compile" />
Original file line number Diff line number Diff line change 1111using K4os . Compression . LZ4 . Streams ;
1212using Perftools . Profiles ;
1313using Xunit ;
14+ using ZstdSharp ;
1415
1516namespace Datadog . Profiler . IntegrationTests . Helpers
1617{
1718 public static class SamplesHelper
1819 {
1920 private static readonly byte [ ] Lz4MagicNumber = BitConverter . GetBytes ( 0x184D2204 ) ;
21+ private static readonly byte [ ] ZstdMagicNumber = BitConverter . GetBytes ( 0xFD2FB528 ) ;
2022
2123 public static int GetSamplesCount ( string directory )
2224 {
@@ -213,6 +215,10 @@ private static Stream GetStream(string filename)
213215 {
214216 return LZ4Stream . Decode ( s ) ;
215217 }
218+ else if ( ZstdMagicNumber . SequenceEqual ( buffer ) )
219+ {
220+ return new DecompressionStream ( s ) ;
221+ }
216222 else
217223 {
218224 return s ;
You can’t perform that action at this time.
0 commit comments