From 371b6c6904ce628b737f9a9e79af84f0f50c783e Mon Sep 17 00:00:00 2001 From: Tristan Sloughter Date: Fri, 17 Apr 2015 18:51:33 -0500 Subject: [PATCH] handle directory that doesn't exist in dscv_util --- src/rlx_dscv_util.erl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/rlx_dscv_util.erl b/src/rlx_dscv_util.erl index fefdbce00..6fe271291 100644 --- a/src/rlx_dscv_util.erl +++ b/src/rlx_dscv_util.erl @@ -72,12 +72,14 @@ format_detail({not_a_directory, EbinDir}) -> -spec discover_dir(process_fun([term()] | term()), file:name(), - directory | file | symlink) -> + directory | file | symlink | undefined) -> [{ok, term()} | {error, Reason::term()}] | [] | {ok, term()} | {error, Reason::term()}. +discover_dir(_ProcessDir, _File, undefined) -> + []; discover_dir(ProcessDir, File, directory) -> case ProcessDir(File, directory) of {ok, Result, true} ->