Skip to content

Commit

Permalink
ios: Disable using STO to save programs to disk
Browse files Browse the repository at this point in the history
Make sure writing to disk is not allowed in DB40X, even using `STO`.

Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
  • Loading branch information
c3d committed Aug 19, 2024
1 parent da9ffe9 commit d1dd893
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,10 @@ void file::open_for_writing(cstring path)
// Open a file for writing
// ----------------------------------------------------------------------------
{
#if NOSAVE
errno = EPERM;
return;
#else
#if SIMULATOR
if (open_count++)
{
Expand All @@ -201,6 +205,7 @@ void file::open_for_writing(cstring path)
data.flag = 0;
}
#endif // SIMULATOR
#endif
}


Expand Down

0 comments on commit d1dd893

Please sign in to comment.