mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 06:26:18 +00:00
Select exception users in EditPrivacyBox.
This commit is contained in:
@@ -742,17 +742,15 @@ namespace internal {
|
||||
|
||||
namespace internal {
|
||||
|
||||
struct SomeAllocatedMemoryChunk {
|
||||
char data[1024 * 1024];
|
||||
};
|
||||
std::unique_ptr<SomeAllocatedMemoryChunk> SomeAllocatedMemory;
|
||||
using ReservedMemoryChunk = std::array<gsl::byte, 1024 * 1024>;
|
||||
std::unique_ptr<ReservedMemoryChunk> ReservedMemory;
|
||||
|
||||
void InstallOperatorNewHandler() {
|
||||
SomeAllocatedMemory = std::make_unique<SomeAllocatedMemoryChunk>();
|
||||
ReservedMemory = std::make_unique<ReservedMemoryChunk>();
|
||||
std::set_new_handler([] {
|
||||
std::set_new_handler(nullptr);
|
||||
SomeAllocatedMemory.reset();
|
||||
t_assert(!"Could not allocate!");
|
||||
ReservedMemory.reset();
|
||||
Unexpected("Could not allocate!");
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user