Miscellaneous fixes:

* util/ioprocsvec.h: Fixed truncating when a write doesn't reach the end
  of stream. [F.Ulivi]
* floptool.cpp: Fixed reversed error checking logic. [F.Ulivi]
* Fixed SUBTARGET=tiny build (required Sega encrypted CPUs to be added).
This commit is contained in:
Vas Crabb 2022-08-28 01:12:08 +10:00
parent 0c79a0a4ec
commit 14e0582083
3 changed files with 5 additions and 3 deletions

View File

@ -67,6 +67,7 @@ MACHINES["NETLIST"] = true
MACHINES["OUTPUT_LATCH"] = true
MACHINES["PIT8253"] = true
MACHINES["RIOT6532"] = true
MACHINES["SEGACRPT"] = true
MACHINES["TICKET"] = true
MACHINES["TIMEKPR"] = true
MACHINES["TTL74148"] = true

View File

@ -188,7 +188,8 @@ private:
{
actual = std::size_t(limit - offset);
std::memmove(reinterpret_cast<std::uint8_t *>(m_storage.data()) + offset, buffer, actual);
m_size = limit;
if (limit > m_size)
m_size = limit;
}
else
{

View File

@ -542,7 +542,7 @@ static int generic_write(image_handler &ih, const char *srcpath, const char *dst
auto dpath = path;
dpath.pop_back();
err = fs->file_create(dpath, meta);
if(!err) {
if(err) {
fprintf(stderr, "File creation failure.\n");
return 1;
}
@ -550,7 +550,7 @@ static int generic_write(image_handler &ih, const char *srcpath, const char *dst
auto dfork = image_handler::fload(srcpath);
err = fs->file_write(path, dfork);
if(!err) {
if(err) {
fprintf(stderr, "File writing failure.\n");
return 1;
}