Don't bother trying locate a full path if the Command looks like a path

Fixes #2
This commit is contained in:
R. Tyler Croy 2017-01-18 21:00:26 -08:00
parent 5993fca640
commit e9895538f3
No known key found for this signature in database
GPG Key ID: 1426C7DC3F51E16F
1 changed files with 6 additions and 0 deletions

View File

@ -84,6 +84,12 @@ package body Arun.Handlers is
Full_Path : aliased constant String := L.Find_Full_Path (Command);
begin
if Command (1) = '/' then
-- If the command starts with a slash, it's likely already a full path so
-- just try to execute it!
L.Execute (Command, Slices);
end if;
if Full_Path /= "" then
Put_Line ("Should Execute: " & Full_Path);
L.Execute (Full_Path, Slices);