| 413 | } |
| 414 | |
| 415 | af_err af_set_memory_manager(af_memory_manager mgr) { |
| 416 | try { |
| 417 | std::unique_ptr<MemoryManagerFunctionWrapper> newManager( |
| 418 | new MemoryManagerFunctionWrapper(mgr)); |
| 419 | // Calls shutdown() on the existing memory manager, but does not free |
| 420 | // the associated handle, if there is one |
| 421 | detail::setMemoryManager(std::move(newManager)); |
| 422 | } |
| 423 | CATCHALL; |
| 424 | |
| 425 | return AF_SUCCESS; |
| 426 | } |
| 427 | |
| 428 | af_err af_unset_memory_manager() { |
| 429 | try { |
no test coverage detected