From e411a75dcd8ee781774c3c9f185e6c699d1b128f Mon Sep 17 00:00:00 2001 From: hamelg Date: Sun, 10 May 2020 00:21:45 +0200 Subject: [PATCH] [FIX] Disable BOM in non-Windows build (#1268) * Disable BOM in non-Windows build * Disable BOM in non-Windows build --- src/lib_ccx/ccx_common_option.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/lib_ccx/ccx_common_option.c b/src/lib_ccx/ccx_common_option.c index 1fc501da..74465c46 100644 --- a/src/lib_ccx/ccx_common_option.c +++ b/src/lib_ccx/ccx_common_option.c @@ -132,7 +132,11 @@ void init_options(struct ccx_s_options *options) options->enc_cfg.start_credits_text = NULL; options->enc_cfg.end_credits_text = NULL; options->enc_cfg.encoding = CCX_ENC_UTF_8; - options->enc_cfg.no_bom = 0; // Use BOM by default. +#ifdef _WIN32 + options->enc_cfg.no_bom = 0; // Use BOM by default for windows only +#else + options->enc_cfg.no_bom = 1; +#endif options->enc_cfg.services_charsets = NULL; options->enc_cfg.all_services_charset = NULL; options->enc_cfg.with_semaphore = 0;