#153 closed Bug (Fixed)
Running process with $STDOUT_CHILD kills ConsoleWrite.
| Reported by: | Owned by: | Valik | |
|---|---|---|---|
| Milestone: | 3.2.11.3 | Component: | AutoIt |
| Version: | 3.2.11.1 | Severity: | |
| Keywords: | Cc: |
Description
When the following code is run nothing appears in the console. It's not a big worry, but I thought it should be reported.
#include <Constants.au3>
Global $iTimer = TimerInit()
Global $iProcess = Run('cmd.exe /c', @SystemDir, @SW_SHOW, $STDOUT_CHILD)
Do
ConsoleWrite('No ConsoleWrite for you!')
Sleep(100)
Until TimerDiff($iTimer) > 5000
StdioClose($iProcess)
ConsoleWrite('That''s all folks!' & @CRLF)
Attachments (2)
Change History (9)
comment:1 by , 18 years ago
comment:2 by , 18 years ago
Hmm, strange. Just found something that may be important. I actually have (in SciTe) a separate hotkey to run a script without the AutoIt wrapper. It is when I do this that I get the confusing results. If I use the AutoIt wrapper I get the expected results in the console.
Without the wrapper I get this in the console:
>"C:\Program Files\AutoIt3\autoit3.exe" /ErrorStdOut "D:\Rob\AutoIt\_Scraps\_scrap.au3" >Exit code: 0 Time: 5.198
I also tried without the /ErrorStdOut, same thing:
>"C:\Program Files\AutoIt3\autoit3.exe" "D:\Rob\AutoIt\_Scraps\_scrap.au3" >Exit code: 0 Time: 5.241
Sorry I didn't think of that before.
comment:3 by , 18 years ago
Baffling. I wonder what obscure dance to a deity I must do to figure this one out. As best I can tell, there's no functional difference in the code between 3.2.10.0 and 3.2.11.x... yet things don't work.
comment:4 by , 18 years ago
Which dance indeed? And which deity for that matter?
I'm just glad I'm not the only one experiencing this bug, you had me worried there for a minute when it wasn't happening to you.
comment:5 by , 18 years ago
| Milestone: | → 3.2.11.3 |
|---|---|
| Owner: | set to |
| Resolution: | → Fixed |
| Status: | new → closed |
Fixed in version: 3.2.11.3
comment:6 by , 18 years ago
If you only knew how obscure this was. I've actually known the entire time what the problem was, but it took some time to write a script to prove it and to debug it. Oh, then there's the fact that I only looked at the issue on 2 occasions in the last couple weeks.
by , 18 years ago
| Attachment: | Parent.au3 added |
|---|

I can not reproduce that either via SciTE or compiling as a Console application. I always get the output as expected.