Commit 021e5501 authored by jdelange's avatar jdelange

* ocarina/src/core/mgmt/ocarina-files.adb

   - Search file returns No_Name if the file name in parameter
     is not valid.
   - Fix bug 206.



git-svn-id: https://tecsw.estec.esa.int/svn/taste/trunk/ocarina@3061 129961e7-ef38-4bb5-a8f7-c9a525a55882
parent 6a99453e
......@@ -180,9 +180,18 @@ package body Ocarina.Files is
function Search_File (File_Name : Name_Id) return Name_Id is
begin
if File_Name = No_Name then
return No_Name;
end if;
-- Check in the current directory first since -I- is not allowed
Get_Name_String (File_Name);
if Name_Len = 0 then
return No_Name;
end if;
if Is_Regular_File (Name_Buffer (1 .. Name_Len)) then
return File_Name;
end if;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment