Skip to content

Commit

Permalink
Turn log level to off before nullifying the logger
Browse files Browse the repository at this point in the history
  • Loading branch information
takameyer committed Jul 4, 2023
1 parent 4830f42 commit cea8db9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

### Fixed
* Fixed updating helpers (the `ClassMap`) used by `Realm` before notifying schema change listeners when the schema is changed during runtime. ([#5574](https://github.com/realm/realm-js/issues/5574))
* Fix crashes on refresh of the React Native application ([#5904](https://github.com/realm/realm-js/issues/5904))

### Compatibility
* React Native >= v0.71.4
Expand Down Expand Up @@ -48,7 +49,7 @@
* Improve performance of equality queries on a non-indexed mixed property by about 30%. ([realm/realm-core#6506](https://github.com/realm/realm-core/pull/6506))
* Improve performance of rolling back write transactions after making changes. ([realm/realm-core#6513](https://github.com/realm/realm-core/pull/6513))
* Extended `PropertySchema.indexed` with the `full-text` option, that allows to create an index for full-text search queries. ([#5755](https://github.com/realm/realm-js/issues/5755))
* Access token refresh for websockets was not updating the location metadata. ([realm/realm-core#6630](https://github.com/realm/realm-core/issues/6630), since v11.9.0)
* Access token refresh for websockets was not updating the location metadata ([realm/realm-core#6630](https://github.com/realm/realm-core/issues/6630), since v11.9.0)
* Fix several UBSan failures which did not appear to result in functional bugs ([realm/realm-core#6649](https://github.com/realm/realm-core/pull/6649)).
* Using both synchronous and asynchronous transactions on the same thread or scheduler could hit an assertion failure if one of the callbacks for an asynchronous transaction happened to be scheduled during a synchronous transaction ([realm/realm-core#6659](https://github.com/realm/realm-core/pull/6649), since v10.12.0)
* Added APIs to facilitate adding and removing subscriptions. ([#5772](https://github.com/realm/realm-js/pull/5772))
Expand Down
1 change: 1 addition & 0 deletions packages/realm/bindgen/src/templates/jsi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1076,6 +1076,7 @@ export function generate({ rawSpec, spec, file: makeFile }: TemplateContext): vo
extern "C" {
void realm_jsi_invalidate_caches() {
// Clear the default logger, to prevent it from holding on to a pointer that was released
realm::util::Logger::set_default_level_threshold(realm::util::Logger::Level::off);
realm::util::Logger::set_default_logger(nullptr);
// Close all cached Realms
realm::_impl::RealmCoordinator::clear_all_caches();
Expand Down

0 comments on commit cea8db9

Please sign in to comment.