aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1/src/asn1ct.erl
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2014-02-20 12:30:27 +0100
committerBjörn Gustavsson <[email protected]>2014-02-20 12:30:27 +0100
commit39c18117df7cb5393fb0164c9aded020941fbddb (patch)
treea8dd9ecd10bcb9126f969a7213d5735f56709c62 /lib/asn1/src/asn1ct.erl
parent4c538e1a857d3dce7cbb8358f9ddd08b25db166e (diff)
parent5c12db17fea6de6f3fc3ce16a7159b6f71ea92f4 (diff)
downloadotp-39c18117df7cb5393fb0164c9aded020941fbddb.tar.gz
otp-39c18117df7cb5393fb0164c9aded020941fbddb.tar.bz2
otp-39c18117df7cb5393fb0164c9aded020941fbddb.zip
Merge branch 'bjorn/asn1/cleanup/OTP-11727'
* bjorn/asn1/cleanup/OTP-11727: asn1ct_check: Use a return value to silence a dialyzer warning asn1ct_check: Remove useless call to check_integer/3 asn1ct_check: Correct error handling for illegal OCTET STRING values asn1ct: Silence dialyzer warnings for unmatched returns asn1ct_table: Remove unused flexibility in table creation asn1ct_table: Silence a dialyzer warning for unmatched return asn1ct_gen: Silence dialyzer warnings for unmatched returns asn1ct_value: Silence a dialyzer warning for unmatched return asn1ct_tok: Check return value from file:close/1
Diffstat (limited to 'lib/asn1/src/asn1ct.erl')
-rw-r--r--lib/asn1/src/asn1ct.erl12
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/asn1/src/asn1ct.erl b/lib/asn1/src/asn1ct.erl
index 531a4935fe..30f493a2df 100644
--- a/lib/asn1/src/asn1ct.erl
+++ b/lib/asn1/src/asn1ct.erl
@@ -1040,7 +1040,7 @@ get_file_list1(Stream,Dir,Includes,Acc) ->
Ret = io:get_line(Stream,''),
case Ret of
eof ->
- file:close(Stream),
+ ok = file:close(Stream),
lists:reverse(Acc);
FileName ->
SuffixedNameList =
@@ -1926,8 +1926,9 @@ read_config_file(ModuleName) ->
Includes = [I || {i,I} <- Options],
read_config_file1(ModuleName,Includes);
{error,Reason} ->
- file:format_error(Reason),
- throw({error,{"error reading asn1 config file",Reason}})
+ Error = "error reading asn1 config file: " ++
+ file:format_error(Reason),
+ throw({error,Error})
end.
read_config_file1(ModuleName,[]) ->
case filename:extension(ModuleName) of
@@ -1945,8 +1946,9 @@ read_config_file1(ModuleName,[H|T]) ->
{error,enoent} ->
read_config_file1(ModuleName,T);
{error,Reason} ->
- file:format_error(Reason),
- throw({error,{"error reading asn1 config file",Reason}})
+ Error = "error reading asn1 config file: " ++
+ file:format_error(Reason),
+ throw({error,Error})
end.
get_config_info(CfgList,InfoType) ->