YoushouldhavereceivedacopyoftheGNUGeneralPublicLicense alongwiththisprogram;ifnot,writetotheFreeSoftware
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA */
if (!(MyFlags & (MY_WME | MY_FAE | MY_FNABP)))
MyFlags|= my_global_flags;
for (;;)
{
errno= 0; /* Linux, Windows don't reset this on EOF/success */ #ifdef _WIN32
readbytes= my_win_pread(Filedes, Buffer, Count, offset); #else
readbytes= pread(Filedes, Buffer, Count, offset); #endif
if (readbytes != Count)
{ /* We should never read with wrong file descriptor! */
DBUG_ASSERT(readbytes != (size_t)-1 || errno != EBADF);
my_errno= errno; if (errno == 0 || (readbytes != (size_t) -1 &&
(MyFlags & (MY_NABP | MY_FNABP))))
my_errno= HA_ERR_FILE_TOO_SHORT;
DBUG_PRINT("warning",("Read only %d bytes off %u from %d, errno: %d",
(int) readbytes, (uint) Count,Filedes,my_errno)); if ((readbytes == 0 || readbytes == (size_t) -1) && errno == EINTR)
{
DBUG_PRINT("debug", ("my_pread() was interrupted and returned %d",
(int) readbytes)); continue; /* Interrupted */
}
/* Do a read retry if we didn't get enough data on first read */ if (readbytes != (size_t) -1 && readbytes != 0 &&
(MyFlags & MY_FULL_IO))
{
Buffer+= readbytes;
Count-= readbytes;
save_count+= readbytes;
offset+= readbytes; continue;
}
if (writtenbytes == Count) break;
my_errno= errno; if (writtenbytes != (size_t) -1)
{ /* Safegueard */
written+=writtenbytes;
Buffer+=writtenbytes;
Count-=writtenbytes;
offset+=writtenbytes;
}
DBUG_PRINT("error",("Write only %u bytes", (uint) writtenbytes)); #ifndef NO_BACKGROUND if (my_thread_var->abort)
MyFlags&= ~ MY_WAIT_IF_FULL; /* End if aborted by user */ if ((my_errno == ENOSPC || my_errno == EDQUOT) &&
(MyFlags & MY_WAIT_IF_FULL))
{
wait_for_free_space(my_filename(Filedes), errors);
errors++; continue;
} if ((writtenbytes && writtenbytes != (size_t) -1) || my_errno == EINTR) continue; /* Retry */ #endif
/* Don't give a warning if it's ok that we only write part of the data */ if (MyFlags & (MY_NABP | MY_FNABP))
{ if (MyFlags & (MY_WME | MY_FAE | MY_FNABP))
my_error(EE_WRITE, MYF(ME_BELL | (MyFlags & (ME_NOTE | ME_ERROR_LOG))),
my_filename(Filedes),my_errno);
DBUG_RETURN(MY_FILE_ERROR); /* Error on write */
} break; /* Return bytes written */
}
DBUG_EXECUTE_IF("check", my_seek(Filedes, -1, SEEK_SET, MYF(0));); if (MyFlags & (MY_NABP | MY_FNABP))
DBUG_RETURN(0); /* Want only errors */
DBUG_RETURN(writtenbytes+written); /* purecov: inspected */
} /* my_pwrite */
Messung V0.5 in Prozent
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.1Bemerkung:
(vorverarbeitet am 2026-10-08)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.