Re: WriteFile()



"Hector Santos" <nospamhere@xxxxxxxxxxxxxx> wrote in message
news:uyxFNMtPFHA.3196@xxxxxxxxxxxxxxxxxxxxxxx

[...]

> Synchronous 100% meant a blocked call.

This is what I said.

[...]

> That has nothing to do with the fact whether there is a timeout
> consideration. It may part of the equation or not.

This is what I said, too.

These two statements contradict with your original statement that
'"synchronous operation" [...] implies block with no timeouts'.

[...]

> For a blocking WriteFile() when *no timeout* is expected or the device
> is prepared for *no timeout* behavior, the call is 100% blocked and there
> are only two possible result:
>
> - Success where request = written
> - Error
>
> Anything else is a unexpected design framework.

'request = written' can be binary if only one byte is involved. If there are
more data, it depends on the medium. For serial ports and sockets, to name
just two, it can be less than the entire data size. This is not Windows
specific.

[...]

> I don't know how much simple it can get or why this is even a question.

It is not. The concept is much older than WriteFile(). Have a look at
_write(). As far as I can tell, it has not changed much since 1972 when what
later became known as the C Standard Library was created. And it may also
complete _successfully_ upon writing _less_ than requested.

S


.



Relevant Pages

  • VIA SATA Raid needs a long time to recover from suspend
    ... Then if there was an IO request made immediately after resuming, ... Changing the timeout resolved this. ... finally did clear) it would timeout and fail. ... It seemed the kernel ...
    (Linux-Kernel)
  • Re: Problems with the block-layer timeouts
    ... clear a idea of when the timeout period should begin. ... Each request has its own timer, and as it is added to the queue, we ... What the driver chooses to do with the ...
    (Linux-Kernel)
  • Big Uploads with IIS 6.0
    ... I've already posted this question on the IIS forum, ... I have an ASP.NET application that does big uploads on ... upload fails randomly (as if the server had given up on the request). ... timeout in the web.config file, ...
    (microsoft.public.dotnet.framework.aspnet)
  • Problems with the block-layer timeouts
    ... clear a idea of when the timeout period should begin. ... Each request has its own timer, and as it is added to the queue, we ... Requeuing ...
    (Linux-Kernel)
  • Re: Timeout errors using Net::HTTP on Windows
    ... Since this weird Net timeout issue has a solution now, ... Be careful not to have too many threads request from ... def rbuf_fill ...
    (comp.lang.ruby)