Using c# and latest version of Groupdocs Comparison, our service hangs on the Compare method using following files and code:
using (MemoryStream sourceStream = new MemoryStream(sourcePdfFile))
{
using (Comparer comparer =
new Comparer(sourceStream))
{
using (MemoryStream targetStream = new MemoryStream(targetPdfFile))
{
comparer.Add(targetStream);
using (MemoryStream outputStream = new MemoryStream())
{
CompareOptions compareOptions = new CompareOptions
{
GenerateSummaryPage = false,
DetectStyleChanges = true,
DetalisationLevel = DetalisationLevel.Middle,
DeletedItemStyle = new StyleSettings()
{
IsStrikethrough = true,
FontColor = Color.Red
},
InsertedItemStyle = new StyleSettings()
{
IsUnderline = true,
FontColor = Color.Green
}
};
comparer.Compare(outputStream, new SaveOptions()
{
}, compareOptions);
memoryleak.zip (74.8 KB)
This is quite urgent as we run our service in production!