问题
I try to handle some pipes in a CAD Programm with c++. The programm Geograf has two pipes. They are both in the following path: \.\pipe\GGPIPE The interesting on this pipe is, that I have to open a pipe then close a pipe and open a pipe again. After this steps, I can send commands through the pipe to Geograf.
My problem or question is, why I can write to pipe the only one time? After I excecute my program the second time, the handle have a INVALID_HANDLE_VALUE.
If I want to send a command again, I have to restart the Geograf programm (and with it, the GGPIPE). After a restart I can send only one command throgh the pipe.
When I write to another given pipe in windows, I can write multiple times.
Is there a way to write multiple times in the GGPIPE? Or can i manipulate a given pipe?
来源:https://stackoverflow.com/questions/35633393/writing-mulitple-times-in-a-special-given-pipe-c