Thu, 15 Jan 2015 21:03:48 +0100
Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #ifndef mozilla_windowsdllblocklist_h
7 #define mozilla_windowsdllblocklist_h
9 #if defined(_MSC_VER) && (defined(_M_IX86) || defined(_M_X64))
11 #include <windows.h>
12 #include "mozilla/GuardObjects.h"
13 #include "nscore.h"
15 #define HAS_DLL_BLOCKLIST
17 NS_IMPORT void DllBlocklist_Initialize();
18 NS_IMPORT void DllBlocklist_SetInXPCOMLoadOnMainThread(bool inXPCOMLoadOnMainThread);
19 NS_IMPORT void DllBlocklist_WriteNotes(HANDLE file);
21 class AutoSetXPCOMLoadOnMainThread
22 {
23 public:
24 AutoSetXPCOMLoadOnMainThread(MOZ_GUARD_OBJECT_NOTIFIER_ONLY_PARAM) {
25 MOZ_GUARD_OBJECT_NOTIFIER_INIT;
26 DllBlocklist_SetInXPCOMLoadOnMainThread(true);
27 }
29 ~AutoSetXPCOMLoadOnMainThread() {
30 DllBlocklist_SetInXPCOMLoadOnMainThread(false);
31 }
33 private:
34 MOZ_DECL_USE_GUARD_OBJECT_NOTIFIER
35 };
37 #endif // defined(_MSC_VER) && (defined(_M_IX86) || defined(_M_X64))
38 #endif // mozilla_windowsdllblocklist_h