diff --git a/src/jitlibs/semihost/semihost.cpp b/src/jitlibs/semihost/semihost.cpp index 964a897030..a793b41d98 100644 --- a/src/jitlibs/semihost/semihost.cpp +++ b/src/jitlibs/semihost/semihost.cpp @@ -1,5 +1,6 @@ #include #include "etiss/ETISS.h" +#include #include "SemihostingCalls.h" @@ -184,7 +185,8 @@ etiss_int64 semihostingCall(ETISS_CPU *const cpu, ETISS_System *const etissSyste std::vector buffer = semihostReadSystemMemory(etissSystem, address, count); - size_t num_written = fwrite(buffer.data(), 1, count, file); + // size_t num_written = fwrite(buffer.data(), 1, count, file); + size_t num_written = write(fd, buffer.data(), count); return count - num_written; } case SYS_READ: