Skip to content

Commit

Permalink
switch name of find_header_file find_header_file2
Browse files Browse the repository at this point in the history
  • Loading branch information
jixiuf committed Sep 20, 2012
1 parent 70f0ba6 commit acfb255
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/distel.erl
Expand Up @@ -1122,7 +1122,7 @@ get_code_path(XREF) ->
end.

%% distel:find_header_file("eunit","include/eunit.hrl").
find_header_file(Application,SubPath)->
find_header_file2(Application,SubPath)->
case code:lib_dir(Application) of
{error,Error}->
{error,Error};
Expand All @@ -1131,16 +1131,16 @@ find_header_file(Application,SubPath)->
end
.

%% distel:find_header_files("eunit/include/eunit.hrl").
find_header_file2(HeaderPathInSrc)->
%% distel:find_header_file2("eunit/include/eunit.hrl").
find_header_file(HeaderPathInSrc)->
Index =string:chr(HeaderPathInSrc,$/),
case Index of
0-> %no $/ found in String
{error,not_a_system_header_file};
Index ->
Application = string:substr(HeaderPathInSrc,1,Index-1),
SubPath = string:substr(HeaderPathInSrc,Index+1),
find_header_file(Application,SubPath)
find_header_file2(Application,SubPath)
end
.

Expand Down

0 comments on commit acfb255

Please sign in to comment.