Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Unified Diff: ui/base/dragdrop/os_exchange_data_provider_win.cc

Issue 1103323004: ui/base/dragdrop: Fix warnings found by clang chromium-style plugin on Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/base/dragdrop/os_exchange_data_provider_win.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/dragdrop/os_exchange_data_provider_win.cc
diff --git a/ui/base/dragdrop/os_exchange_data_provider_win.cc b/ui/base/dragdrop/os_exchange_data_provider_win.cc
index 64330ee3bbaff34c75232702409d6289d50c04b2..ac57ffc1fc24e004ab57d44bd4f6d9b0a2cac616 100644
--- a/ui/base/dragdrop/os_exchange_data_provider_win.cc
+++ b/ui/base/dragdrop/os_exchange_data_provider_win.cc
@@ -626,6 +626,20 @@ static void DuplicateMedium(CLIPFORMAT source_clipformat,
destination->pUnkForRelease->AddRef();
}
+DataObjectImpl::StoredDataInfo::StoredDataInfo(const FORMATETC& format_etc,
+ STGMEDIUM* medium)
+ : format_etc(format_etc), medium(medium), owns_medium(true) {
+}
+
+DataObjectImpl::StoredDataInfo::~StoredDataInfo() {
+ if (owns_medium) {
+ ReleaseStgMedium(medium);
+ delete medium;
+ }
+ if (downloader.get())
+ downloader->Stop();
+}
+
DataObjectImpl::DataObjectImpl()
: is_aborting_(false),
in_drag_loop_(false),
« no previous file with comments | « ui/base/dragdrop/os_exchange_data_provider_win.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698