Failed to register for BoringSSL log debug updates

2019-03-09 03:40发布

问题:

When debugging app in Xcode 9 beta while it's running on iPhone with iOS 11 beta installed, I started to notice following messages when performing networking calls:

[] network_config_register_boringssl_log_debug_updates Failed to register for BoringSSL log debug updates
[BoringSSL] Function boringssl_context_get_peer_npn_data: line 1212 Peer's advertised NPN data is NULL or empty

Any idea what is causing this?

回答1:

Open the Xcode Scheme editor and add a new environment variable OS_ACTIVITY_MODE and set to disable.



回答2:

This approach seems to stop all NSLog logging, which is a problem. For a more nuanced approach that builds on the accepted answer, above, but does not eliminate all NSLog logging, see the answer by cduhn at Hide strange unwanted Xcode 8 logs.