ACE+TAO-7_0_8
[ACE_TAO.git] / ACE / tests / Bug_3334_Regression_Test.cpp
blob9f129fb08de13fba498198798fdedfaba1a1643f
1 // ============================================================================
2 //
3 // = LIBRARY
4 // tests
5 //
6 // = DESCRIPTION
7 // This test exercises ACE_Service_Config SEGV during shutdown when
8 // Modules get double deleted. Once by Stream parent,
9 // once by ACE_Service_Repository
11 // = AUTHOR
12 // Chad Beaulac <chad@objectivesolutions.com>
14 // ============================================================================
16 #include "test_config.h"
17 #include "ace/Log_Msg.h"
18 #include "ace/Service_Config.h"
22 int
23 run_main (int, ACE_TCHAR *argv[])
25 ACE_START_TEST (ACE_TEXT ("Bug_3334_Regression_Test"));
27 ACE_TCHAR *_argv[3] = { argv[0],
28 const_cast<ACE_TCHAR*> (ACE_TEXT ("-f")),
29 const_cast<ACE_TCHAR*>
30 (ACE_TEXT ("Bug_3334_Regression_Test.conf")) };
31 int status = 0;
32 if ((status = ACE_Service_Config::open (3,
33 _argv,
34 ACE_DEFAULT_LOGGER_KEY,
35 true,
36 true /*ignore def svc.conf*/)) == -1)
37 ACE_ERROR ((LM_ERROR,
38 ACE_TEXT ("%p\n"),
39 ACE_TEXT ("open"),
40 1));
42 ACE_Service_Config::fini_svcs ();
44 ACE_END_TEST;
45 return status;