aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2014-01-22 10:10:44 +0100
committerDan Gudmundsson <[email protected]>2014-01-22 10:10:44 +0100
commitd203887853971d58a4054400a88f91bbf73b19c8 (patch)
tree7b442151bd7b6f37119096913d90f72437db0510 /lib/stdlib
parent1f7e86af8b3f489253c06b2043440c11168a4654 (diff)
parentc0d320e028ce4a4b6af99ad5e20dee8ea95d6fce (diff)
downloadotp-d203887853971d58a4054400a88f91bbf73b19c8.tar.gz
otp-d203887853971d58a4054400a88f91bbf73b19c8.tar.bz2
otp-d203887853971d58a4054400a88f91bbf73b19c8.zip
Merge branch 'dgud/test_unicode/OTP-10877'
* dgud/test_unicode/OTP-10877: sasl test: Quote executable paths (can contain spaces) rt_tools: Handle unicode chars in printouts kernel: code_SUITE fix unicode option Fix (unicode) debug info in test cases stdlib: Fix format if module resides in a unicode directory Fix testing with unicode paths test_server: Fix ts write unicode in config files
Diffstat (limited to 'lib/stdlib')
-rw-r--r--lib/stdlib/src/c.erl4
-rw-r--r--lib/stdlib/test/shell_SUITE.erl18
2 files changed, 11 insertions, 11 deletions
diff --git a/lib/stdlib/src/c.erl b/lib/stdlib/src/c.erl
index f23b5d4fe9..c2256c0cf9 100644
--- a/lib/stdlib/src/c.erl
+++ b/lib/stdlib/src/c.erl
@@ -455,7 +455,7 @@ m() ->
foreach(fun ({Mod,File}) -> mformat(Mod, File) end, sort(code:all_loaded())).
mformat(A1, A2) ->
- format("~-20s ~s\n", [A1,A2]).
+ format("~-20s ~ts\n", [A1,A2]).
%% erlangrc(Home)
%% Try to run a ".erlang" file, first in the current directory
@@ -721,7 +721,7 @@ ls(Dir) ->
{error, enotdir} ->
ls_print([Dir]);
{error, Error} ->
- format("~s\n", [file:format_error(Error)])
+ format("~ts\n", [file:format_error(Error)])
end.
ls_print([]) -> ok;
diff --git a/lib/stdlib/test/shell_SUITE.erl b/lib/stdlib/test/shell_SUITE.erl
index 233ba0764f..692dfe0faa 100644
--- a/lib/stdlib/test/shell_SUITE.erl
+++ b/lib/stdlib/test/shell_SUITE.erl
@@ -146,7 +146,7 @@ start_restricted_from_shell(Config) when is_list(Config) ->
"test_restricted) end.">>),
?line {ok, test_restricted} =
application:get_env(stdlib, restricted_shell),
- ?line "Module" ++ _ = t(<<"begin m() end.">>),
+ ?line "Module" ++ _ = t({<<"begin m() end.">>, utf8}),
?line "exception exit: restricted shell does not allow c(foo)" =
comm_err(<<"begin c(foo) end.">>),
?line "exception exit: restricted shell does not allow init:stop()" =
@@ -225,7 +225,7 @@ start_restricted_on_command_line(Config) when is_list(Config) ->
?line {ok,Node2} = start_node(shell_suite_helper_2,
"-pa "++?config(priv_dir,Config)++
" -stdlib restricted_shell test_restricted2"),
- ?line "Module" ++ _ = t({Node2,<<"begin m() end.">>}),
+ ?line "Module" ++ _ = t({Node2,<<"begin m() end.">>, utf8}),
?line "exception exit: restricted shell does not allow c(foo)" =
comm_err({Node2,<<"begin c(foo) end.">>}),
?line "exception exit: restricted shell does not allow init:stop()" =
@@ -2927,14 +2927,14 @@ t1(Parent, {Bin,Enc}, F) ->
server_loop(S)
catch exit:R -> Parent ! {self(), R};
throw:{?MODULE,LoopReply,latin1} ->
- L0 = binary_to_list(list_to_binary(LoopReply)),
- [$\n | L1] = lists:dropwhile(fun(X) -> X =/= $\n end, L0),
- Parent ! {self(), dotify(L1)};
+ L0 = binary_to_list(list_to_binary(LoopReply)),
+ [$\n | L1] = lists:dropwhile(fun(X) -> X =/= $\n end, L0),
+ Parent ! {self(), dotify(L1)};
throw:{?MODULE,LoopReply,_Uni} ->
- Tmp = unicode:characters_to_binary(LoopReply),
- L0 = unicode:characters_to_list(Tmp),
- [$\n | L1] = lists:dropwhile(fun(X) -> X =/= $\n end, L0),
- Parent ! {self(), dotify(L1)}
+ Tmp = unicode:characters_to_binary(LoopReply),
+ L0 = unicode:characters_to_list(Tmp),
+ [$\n | L1] = lists:dropwhile(fun(X) -> X =/= $\n end, L0),
+ Parent ! {self(), dotify(L1)}
after group_leader(S#state.leader, self())
end.