Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Why is my overlapped WriteFile blocking?

Why is my overlapped WriteFile blocking?

Scheduled Pinned Locked Moved C / C++ / MFC
helpsysadminquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    JT Anderson
    wrote on last edited by
    #1

    I have a named pipe client that is using overlapped I/O on a handle registered with an I/O completion port. There was a bug in the server that was causing it to never read the named pipe, which in turn caused me to notice that the overlapped WriteFile call in the client was getting blocked. My overlapped ReadFile calls are not being blocked. After fixing the server bug, it appears that the WriteFile calls are always completing before WriteFile returns. I never seem to get ERROR_IO_PENDING back on a write. The write completion events ARE being properly posted to the IOCP. I did open the named pipe with FILE_FLAG_OVERLAPPED. (If I hadn't, I don't think the overlapped reads would be working properly.) Any suggestions? -------- There are 10 types of people in this world. Those who know binary and those who don't.

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups