global-functions: $WaitForFile: declare input first

This commit is contained in:
Christian Hesse 2021-01-20 14:07:20 +01:00
parent dc148065dc
commit fa7f37e87f

View file

@ -1033,9 +1033,11 @@
# wait for file to be available # wait for file to be available
:set WaitForFile do={ :set WaitForFile do={
:local FileName [ :tostr $1 ];
:global CleanFilePath; :global CleanFilePath;
:local FileName [ $CleanFilePath [ :tostr $1 ] ]; :set FileName [ $CleanFilePath $FileName ];
:local I 0; :local I 0;
:while ([ :len [ / file find where name=$FileName ] ] = 0) do={ :while ([ :len [ / file find where name=$FileName ] ] = 0) do={