aboutsummaryrefslogtreecommitdiffstats
path: root/erts/preloaded/src
diff options
context:
space:
mode:
authorSiri Hansen <[email protected]>2013-06-05 14:58:58 +0200
committerSiri Hansen <[email protected]>2013-06-05 14:58:58 +0200
commit3a40a631313ea3a5b05de121ebd6a559d8543329 (patch)
tree846a70b93f4870e5dcaeae7026b67f4afe5f3db1 /erts/preloaded/src
parent00e93e8948c84bc5150e3c8dbea0820e60491461 (diff)
parentb81d9bf18cd99b60f4bd964f190f63673e0a9b6b (diff)
downloadotp-3a40a631313ea3a5b05de121ebd6a559d8543329.tar.gz
otp-3a40a631313ea3a5b05de121ebd6a559d8543329.tar.bz2
otp-3a40a631313ea3a5b05de121ebd6a559d8543329.zip
Merge branch 'siri/install-otp-in-unicode-path'
* siri/install-otp-in-unicode-path: [sasl] Remove priv dir after release_handler_SUITE Update preloaded init.beam Allow unicode characters for boot and config in init:make_permanent [sasl] Clean priv_dir after systools_SUITE [reltool] Use unicode characters in work dir for unicode test [sasl] Use unicode characters in priv dir name also on windows [reltool] Write erl.ini as UTF-8 [sasl] Update tests to run under unicode path [sasl] Rewrite release_handler_SUITE:clean_priv_dir to work on unicode paths [sasl] Update example/target_system.erl to handle unicode [sasl] Write erl.ini as utf8, allowing unicode path for root dir and bin dir
Diffstat (limited to 'erts/preloaded/src')
-rw-r--r--erts/preloaded/src/init.erl5
1 files changed, 4 insertions, 1 deletions
diff --git a/erts/preloaded/src/init.erl b/erts/preloaded/src/init.erl
index 87003d096b..ab8464956c 100644
--- a/erts/preloaded/src/init.erl
+++ b/erts/preloaded/src/init.erl
@@ -465,7 +465,10 @@ make_permanent(Boot,Config,Flags0,State) ->
set_flag(_Flag,false,Flags) ->
{ok,Flags};
set_flag(Flag,Value,Flags) when is_list(Value) ->
- case catch list_to_binary(Value) of
+ %% The flag here can be -boot or -config, which means the value is
+ %% a file name! Thus the file name encoding is used when coverting.
+ Encoding = file:native_name_encoding(),
+ case catch unicode:characters_to_binary(Value,Encoding,Encoding) of
{'EXIT',_} ->
{error,badarg};
AValue ->