diff options
author | Ingela Anderton Andin <[email protected]> | 2015-06-08 16:00:24 +0200 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2015-06-08 16:00:24 +0200 |
commit | a0e14d9c307cd4d1ae964171ff0812bad0a94ef0 (patch) | |
tree | 45ab93b9e059b2b6734b59ad88f1e05f48dea924 /lib/inets/src/http_server/httpd_util.erl | |
parent | f1dede329de90e4805cd21a43bb5b19e288c81a3 (diff) | |
parent | 855c9bb101ed6fc5a3965d1ff0e18c04a346e9cd (diff) | |
download | otp-a0e14d9c307cd4d1ae964171ff0812bad0a94ef0.tar.gz otp-a0e14d9c307cd4d1ae964171ff0812bad0a94ef0.tar.bz2 otp-a0e14d9c307cd4d1ae964171ff0812bad0a94ef0.zip |
Merge branch 'ia/inets/name-spaces/OTP-12674'
* ia/inets/name-spaces/OTP-12674:
inets: Modernize code
inets: Add profile option
Diffstat (limited to 'lib/inets/src/http_server/httpd_util.erl')
-rw-r--r-- | lib/inets/src/http_server/httpd_util.erl | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/lib/inets/src/http_server/httpd_util.erl b/lib/inets/src/http_server/httpd_util.erl index 0d04a75205..b1ddc1abbb 100644 --- a/lib/inets/src/http_server/httpd_util.erl +++ b/lib/inets/src/http_server/httpd_util.erl @@ -572,7 +572,10 @@ make_name(Prefix,Port) -> make_name(Prefix,Addr,Port) -> make_name(Prefix,Addr,Port,""). - + +make_name(Prefix, Addr,Port,Postfix) when is_atom(Postfix)-> + make_name(Prefix, Addr,Port, atom_to_list(Postfix)); + make_name(Prefix,"*",Port,Postfix) -> make_name(Prefix,undefined,Port,Postfix); @@ -595,15 +598,7 @@ make_name2({A,B,C,D}) -> io_lib:format("~w_~w_~w_~w", [A,B,C,D]); make_name2({A, B, C, D, E, F, G, H}) -> - io_lib:format("~s_~s_~s_~s_~s_~s_~s_~s", [integer_to_hexlist(A), - integer_to_hexlist(B), - integer_to_hexlist(C), - integer_to_hexlist(D), - integer_to_hexlist(E), - integer_to_hexlist(F), - integer_to_hexlist(G), - integer_to_hexlist(H) - ]); + io_lib:format("~w_~w_~w_~w_~w_~w_~w_~w", [A,B,C,D,E,F,G,H]); make_name2(Addr) -> search_and_replace(Addr,$.,$_). |