일반적으로 존재하지 않는 파일을 복사하려고 하면 다음과 같은 오류 메시지가 나타납니다.
C:\temp>copy foo bar
The system cannot find the file specified.
해당 오류 메시지는 STDERR에 기록될 것으로 예상하지만 STDOUT에 기록된 것으로 보입니다.
C:\temp>copy foo bar >out
C:\temp>dir
Directory of C:\temp
23/09/2019 16:18 44 out
1 File(s) 44 bytes
0 Dir(s) 885,229,346,816 bytes free
C:\temp>type out
The system cannot find the file specified.
STDOUT과 별도로 STDERR을 리디렉션하는 경우에도 동일한 현상이 발생합니다.
C:\temp>del out
C:\temp>copy foo bar 2>err >out
C:\temp>dir
Directory of C:\temp
23/09/2019 16:10 0 err
23/09/2019 16:10 44 out
2 File(s) 44 bytes
0 Dir(s) 885,226,635,264 bytes free
C:\temp>type out
The system cannot find the file specified.
나는 Windows 10을 사용하고 있습니다
C:\temp>ver
Microsoft Windows [Version 10.0.18362.356]
COPY가 STDERR에 오류 메시지를 쓰지 않는 이유는 무엇입니까? 이 동작은 어디에 문서화되어 있나요?