"Fossies" - the Fresh Open Source Software Archive

Member "burp-2.3.6/src/win32/utest/main.cpp" (28 Apr 2019, 2015 Bytes) of package /linux/privat/burp-2.3.6.tar.bz2:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "main.cpp" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 2.3.0_vs_2.3.6.

    1 /*
    2    Bacula® - The Network Backup Solution
    3 
    4    Copyright (C) 2007-2007 Free Software Foundation Europe e.V.
    5 
    6    The main author of Bacula is Kern Sibbald, with contributions from
    7    many others, a complete list can be found in the file AUTHORS.
    8    This program is Free Software; you can redistribute it and/or
    9    modify it under the terms of version three of the GNU Affero General Public
   10    License as published by the Free Software Foundation, which is
   11    listed in the file LICENSE.
   12 
   13    This program is distributed in the hope that it will be useful, but
   14    WITHOUT ANY WARRANTY; without even the implied warranty of
   15    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
   16    General Public License for more details.
   17 
   18    You should have received a copy of the GNU Affero General Public License
   19    along with this program; if not, write to the Free Software
   20    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
   21    02110-1301, USA.
   22 
   23    Bacula® is a registered trademark of Kern Sibbald.
   24    The licensor of Bacula is the Free Software Foundation Europe
   25    (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
   26    Switzerland, email:ftf@fsfeurope.org.
   27 */
   28 /*
   29  * Kern Sibbald, August 2007
   30  */
   31 
   32 #include "burp.h"
   33 #include <signal.h>
   34 
   35 #undef  _WIN32_IE
   36 #define _WIN32_IE 0x0501
   37 #undef  _WIN32_WINNT
   38 #define _WIN32_WINNT 0x0501
   39 #include <commctrl.h>
   40 
   41 #include <vss.h>
   42 
   43 // Globals
   44 HINSTANCE appInstance;
   45 bool have_service_api;
   46 
   47 extern int UtestMain(int argc, char *argv[], char *envp[]);
   48 
   49 // Main Windows entry point.
   50 int main(int argc, char *argv[], char *envp[])
   51 {
   52     int ret;
   53 
   54     InitWinAPIWrapper();
   55 
   56     // Start up Volume Shadow Copy.
   57     if(VSSInit()) return 1;
   58 
   59     // Startup networking
   60     WSA_Init();
   61 
   62     // Set this process to be the last application to be shut down.
   63     if(p_SetProcessShutdownParameters)
   64         p_SetProcessShutdownParameters(0x100, 0);
   65 
   66     // Call the main code
   67     ret=UtestMain(argc, argv, envp);
   68 
   69     // Terminate our main message loop
   70     PostQuitMessage(0);
   71 
   72     WSACleanup();
   73     return ret;
   74 }