diff options
author | Jose <jose@zeroc.com> | 2018-06-06 19:48:11 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2018-06-06 19:48:57 +0200 |
commit | a93cb6bfcaa59ebd753cacd188514bdb87648bd8 (patch) | |
tree | 6bec028432912e691088475ac8a2d1af550b414a /cpp/test/ios/controller/Bundle/ControllerI.mm | |
parent | Fixed bug where binary distribution testing would fail to build the TestCommo... (diff) | |
download | ice-a93cb6bfcaa59ebd753cacd188514bdb87648bd8.tar.bz2 ice-a93cb6bfcaa59ebd753cacd188514bdb87648bd8.tar.xz ice-a93cb6bfcaa59ebd753cacd188514bdb87648bd8.zip |
iOS test controller fixes
Diffstat (limited to 'cpp/test/ios/controller/Bundle/ControllerI.mm')
-rw-r--r-- | cpp/test/ios/controller/Bundle/ControllerI.mm | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/cpp/test/ios/controller/Bundle/ControllerI.mm b/cpp/test/ios/controller/Bundle/ControllerI.mm index 7a3aca76931..01ce5e193de 100644 --- a/cpp/test/ios/controller/Bundle/ControllerI.mm +++ b/cpp/test/ios/controller/Bundle/ControllerI.mm @@ -31,9 +31,6 @@ namespace class ControllerHelperI : public Test::ControllerHelper, private IceUtil::Monitor<IceUtil::Mutex>, public IceUtil::Thread -#ifdef ICE_CPP11_MAPPING - , public enable_shared_from_this<ControllerHelperI> -#endif { public: @@ -67,7 +64,6 @@ namespace std::ostringstream _out; IceInternal::UniquePtr<Test::TestHelper> _helper; }; - ICE_DEFINE_PTR(ControllerHelperIPtr, ControllerHelperI); class ProcessI : public Process { @@ -133,6 +129,11 @@ _status(0) ControllerHelperI::~ControllerHelperI() { + if(_helper) + { + _helper.release(); + } + if(_handle) { CFBundleUnloadExecutable(_handle); @@ -311,7 +312,9 @@ ControllerHelperI::getOutput() const return _out.str(); } -ProcessI::ProcessI(id<ControllerView> controller, ControllerHelperI* helper) : _controller(controller), _helper(helper) +ProcessI::ProcessI(id<ControllerView> controller, ControllerHelperI* helper) : + _controller(controller), + _helper(helper) { } @@ -356,7 +359,7 @@ ProcessControllerI::start(const string& testSuite, const string& exe, const Stri std::string prefix = std::string("test/") + testSuite; replace(prefix.begin(), prefix.end(), '/', '_'); [_controller println:[NSString stringWithFormat:@"starting %s %s... ", testSuite.c_str(), exe.c_str()]]; - ControllerHelperIPtr helper = ICE_MAKE_SHARED(ControllerHelperI, _controller, prefix + '/' + exe + ".bundle", args); + IceUtil::Handle<ControllerHelperI> helper(new ControllerHelperI(_controller, prefix + '/' + exe + ".bundle", args)); // // Use a 768KB thread stack size for the objects test. This is necessary when running the |