File tree 2 files changed +1
-18
lines changed
src/darwin/Framework/CHIP
2 files changed +1
-18
lines changed Original file line number Diff line number Diff line change 70
70
using namespace chip ::Controller;
71
71
using namespace chip ::Tracing::DarwinFramework;
72
72
73
- static bool sExitHandlerRegistered = false ;
74
- static void ShutdownOnExit ()
75
- {
76
- // Don't do anything here, period
77
- }
78
-
79
73
@interface MTRDeviceControllerFactoryParams ()
80
74
81
75
// Flag to keep track of whether our .storage is real consumer-provided storage
@@ -389,17 +383,6 @@ - (BOOL)_startControllerFactory:(MTRDeviceControllerFactoryParams *)startupParam
389
383
SuccessOrExit (err = _controllerFactory->Init (params));
390
384
}
391
385
392
- // This needs to happen after DeviceControllerFactory::Init,
393
- // because that creates (lazily, by calling functions with
394
- // static variables in them) some static-lifetime objects.
395
- if (!sExitHandlerRegistered ) {
396
- if (atexit (ShutdownOnExit) != 0 ) {
397
- char error[128 ];
398
- strerror_r (errno, error, sizeof (error));
399
- MTR_LOG_ERROR (" Warning: Failed to register atexit handler: %s" , error);
400
- }
401
- sExitHandlerRegistered = true ;
402
- }
403
386
HeapObjectPoolExitHandling::IgnoreLeaksOnExit ();
404
387
405
388
// Make sure we don't leave a system state running while we have no
Original file line number Diff line number Diff line change @@ -607,7 +607,7 @@ + (NSUInteger)generateRandomPIN
607
607
return setupPIN;
608
608
}
609
609
610
- // We got pretty unlikely with our random number generation. Just try
610
+ // We got pretty unlucky with our random number generation. Just try
611
611
// again. The chance that this loop does not terminate in a reasonable
612
612
// amount of time is astronomically low, assuming arc4random_uniform is not
613
613
// broken.
You can’t perform that action at this time.
0 commit comments