We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3af238c commit 3cabc58Copy full SHA for 3cabc58
src/WinWebDiffLib/WebDiffWindow.hpp
@@ -1128,8 +1128,14 @@ class CWebDiffWindow : public IWebDiffWindow
1128
std::shared_ptr<const std::list<ModifiedNode>> nodes,
1129
IWebDiffCallback* callback)
1130
{
1131
- ComPtr<IWebDiffCallback> callback2(callback);
1132
size_t size = nodes->size();
+ if (size == 0)
1133
+ {
1134
+ if (callback)
1135
+ callback->Invoke({ S_OK, nullptr });
1136
+ return S_OK;
1137
+ }
1138
+ ComPtr<IWebDiffCallback> callback2(callback);
1139
auto count = std::make_shared<size_t>();
1140
for (auto it = nodes->rbegin(); it != nodes->rend(); ++it)
1141
0 commit comments