Skip to content

Commit

Permalink
Minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Kagamma committed Jul 10, 2023
1 parent f70d6ea commit d96e684
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/commands.pas
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,8 @@ procedure CommandOpen;
FinishCommand;
Exit;
end;
Files.Open(InputBuffer1);
if InputBuffer1 <> '' then
Files.Open(InputBuffer1);
end;

procedure CommandSave;
Expand Down
4 changes: 2 additions & 2 deletions src/files.pas
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,14 @@ procedure Open(const Path: String);
S: String;
begin
Screen.RenderStatusBarBlank;
Memory.Init;
M := Memory.First;
AssignFile(F, Path);
{$I-}
Reset(F);
{$I+}
if IOResult = 0 then
begin
Memory.Init;
M := Memory.First;
while not EOF(F) do
begin
if Total mod 100 = 0 then
Expand Down

0 comments on commit d96e684

Please sign in to comment.