VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/VBoxHook/dllmain.cpp

Last change on this file was 98103, checked in by vboxsync, 17 months ago

Copyright year updates by scm.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.5 KB
RevLine 
[46182]1/* $Id: dllmain.cpp 98103 2023-01-17 14:15:46Z vboxsync $ */
[8387]2/** @file
3 * VBoxHook -- Global windows hook dll
[46182]4 */
5
6/*
[98103]7 * Copyright (C) 2006-2023 Oracle and/or its affiliates.
[4071]8 *
[96407]9 * This file is part of VirtualBox base platform packages, as
10 * available from https://www.virtualbox.org.
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation, in version 3 of the
15 * License.
16 *
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, see <https://www.gnu.org/licenses>.
24 *
25 * SPDX-License-Identifier: GPL-3.0-only
[8387]26 */
27
28
[63097]29#include <iprt/cdefs.h>
[62679]30#include <iprt/win/windows.h>
[46182]31
32
[8387]33/**
34 * Dll entrypoint
35 *
36 * @returns type size or 0 if unknown type
37 * @param hDLLInst Dll instance handle
38 * @param fdwReason Callback reason
[63094]39 * @param pvReserved Reserved
[8387]40 */
[63094]41BOOL WINAPI DllMain(HINSTANCE hDLLInst, DWORD fdwReason, LPVOID pvReserved)
[8387]42{
[63098]43 RT_NOREF(hDLLInst, pvReserved);
[26493]44 switch (fdwReason)
[8387]45 {
[46182]46 case DLL_PROCESS_ATTACH:
47 return TRUE;
[8387]48
[46182]49 case DLL_PROCESS_DETACH:
50 return TRUE;
[8387]51
[46182]52 case DLL_THREAD_ATTACH:
53 return TRUE;
[8387]54
[46182]55 case DLL_THREAD_DETACH:
56 return TRUE;
[8387]57
[46182]58 default:
59 return TRUE;
[8387]60 }
61}
62
Note: See TracBrowser for help on using the repository browser.

© 2023 Oracle
ContactPrivacy policyTerms of Use