-
Notifications
You must be signed in to change notification settings - Fork 18k
io: Unable to write more than 65536 (2^16) bytes #68618
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
pipes are not unlimited buffers, and echo does not read from stdin. Unlike many projects, the Go project does not use GitHub Issues for general discussion or asking questions. GitHub Issues are used for tracking bugs and proposals only. For questions please refer to https://github.com/golang/go/wiki/Questions |
Yes, its probably due to the following:
What worked for me:Should have directly set the input stream to a file ( |
Go version
go version go1.20.11 linux/amd64
Output of
go env
in your module/workspace:What did you do?
Trying to write a byte array into a command's input stream (stdinpipe)
Following is the dummy snippet wrote for demonstration, which is running a command, reading a file with over 70,000 bytes.
It remains stuck on
write_closer.Write(file_bytes)
forever.Maybe what I'm doing is not the correct way?
Sinppet
Output
What did you see happen?
It was observed that the program remains stuck on line
write_closer.Write(file_bytes)
What did you expect to see?
I expected it to write all the bytes.
The text was updated successfully, but these errors were encountered: