From ff8a1ba0b616c1c625275f9b75b3ecbebfcec221 Mon Sep 17 00:00:00 2001 From: Andreas Grois Date: Tue, 20 Apr 2021 23:50:11 +0200 Subject: Enforce system allocator (sanity and such...) --- swaystatus/src/main.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/swaystatus/src/main.rs b/swaystatus/src/main.rs index 87608a9..664df52 100644 --- a/swaystatus/src/main.rs +++ b/swaystatus/src/main.rs @@ -9,11 +9,13 @@ extern crate gettextrs; use gettextrs::*; use crossbeam_utils::thread; use std::sync::mpsc; -use dirs; #[cfg(test)] pub mod test_plugin; +#[global_allocator] +static GLOBAL : std::alloc::System = std::alloc::System; + fn main() { let text_domain = match dirs::data_dir() { Some (p) => TextDomain::new("swaystatus").prepend("target").push(p), -- cgit v1.2.3