Skip to content

Commit

Permalink
Correct argument to erlang:error/2
Browse files Browse the repository at this point in the history
  • Loading branch information
msantos committed Jan 27, 2014
1 parent 1ba95fb commit 9b1342e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/procket.erl
Expand Up @@ -342,15 +342,15 @@ optarg({interface, Name}) when is_list(Name) ->
true -> true ->
switch("I", Name); switch("I", Name);
false -> false ->
erlang:error(badarg, {interface, Name}) erlang:error(badarg, [{interface, Name}])
end; end;


optarg({dev, Dev}) when is_list(Dev) -> optarg({dev, Dev}) when is_list(Dev) ->
case is_device(Dev) of case is_device(Dev) of
true -> true ->
switch("d", Dev); switch("d", Dev);
false -> false ->
erlang:error(badarg, {dev, Dev}) erlang:error(badarg, [{dev, Dev}])
end; end;


% Ignore any other arguments % Ignore any other arguments
Expand Down

0 comments on commit 9b1342e

Please sign in to comment.