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

Unified Diff: remoting/host/clipboard_win.cc

Issue 792413003: Added impersonation of the anonymous token around CloseClipboard (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 | « no previous file | ui/base/clipboard/clipboard_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/clipboard_win.cc
diff --git a/remoting/host/clipboard_win.cc b/remoting/host/clipboard_win.cc
index 21ae6c77395d1e26c030260cd0eab96e72cc6530..bc062e7aadbc35e521334709b44bb1bf5d8129a0 100644
--- a/remoting/host/clipboard_win.cc
+++ b/remoting/host/clipboard_win.cc
@@ -32,7 +32,9 @@ class ScopedClipboard {
~ScopedClipboard() {
if (opened_) {
+ ::ImpersonateAnonymousToken(GetCurrentThread());
jschuh 2014/12/11 17:53:06 I know the impersonate *shouldn't* fail, but it's
dcheng 2014/12/11 18:18:23 Can we use a scoper to wrap this logic? ... also,
::CloseClipboard();
+ ::RevertToSelf();
}
}
« no previous file with comments | « no previous file | ui/base/clipboard/clipboard_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698