You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// normalize \n to \r\n when pty is accepted.// this is a hardcoded shortcut since we don't support terminal modes.p=bytes.Replace(p, []byte{'\n'}, []byte{'\r', '\n'}, -1)
p=bytes.Replace(p, []byte{'\r', '\r', '\n'}, []byte{'\r', '\n'}, -1)
What happened? What is expected?
I put a file into snips.sh that had a single line with a \n character at the end (no \r).
On another system, I retrieved the file using ssh.
I compared the sha256 of the source and the retrieved file and they were not the same.
snips.sh seems to have added a \r before the \n. :(
I expect snips.sh not to change my files in any way whatsoever.
How can we reproduce it?
root@staging:/# echo 'hi' | od -a
0000000 h i nl
0000003
root@staging:/# echo 'hi' | ssh snips.sh
Pseudo-terminal will not be allocated because stdin is not a terminal.
┃ File Uploaded 📤
┃ id: qbH7FNuWG8
┃ size: 3 B • type: plaintext • visibility: public
┃ SSH 📠
┃ ssh f:[email protected]
┃ URL 🔗
┃ https://snips.sh/f/qbH7FNuWG8
root@staging:/# ssh f:[email protected] | od -a
Connection to snips.sh closed.
0000000 h i cr nl
0000004
Anything else we need to know?
no
The text was updated successfully, but these errors were encountered: