From 7a0572de8014bb267b9f7c14734bce78c4b890d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=94=D0=B0=D0=BC=D1=98=D0=B0=D0=BD=20=D0=93=D0=B5=D0=BE?= =?UTF-8?q?=D1=80=D0=B3=D0=B8=D0=B5=D0=B2=D1=81=D0=BA=D0=B8?= Date: Fri, 3 Aug 2018 14:01:11 +0200 Subject: [PATCH] use system alocator instead of jmalloc Rust 1.28 feature. saves 300kb in executable size --- Cargo.toml | 2 +- src/main.rs | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index be1c840..d8de961 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "http-server" -version = "0.7.0" +version = "0.8.0" authors = ["Damjan Georgievski "] license = "MIT" readme = "README.md" diff --git a/src/main.rs b/src/main.rs index 0e16d30..d383afe 100644 --- a/src/main.rs +++ b/src/main.rs @@ -8,6 +8,11 @@ extern crate percent_encoding; #[macro_use] extern crate clap; #[macro_use] extern crate log; +use std::alloc::System; + +#[global_allocator] +static GLOBAL: System = System; + mod channel; mod web;