Still unsafe: write_sha1_from_fd()

From: Linus Torvalds <torvalds@osdl.org>
Date: 2016-06-15 22:42:08

I was looking over the object writing functions, and noticed that 
"write_sha1_from_fd()" writes its object directly into the final object 
name, which means that if it is interrupted with ^C at an inopportune 
time, it will leave a corrupt object behind.

The only user is apparently ssh-fetch, but especially since the input-fd 
is a network connection, it looks like it is not at all unlikely that this 
case will trigger - all it takes is somebody impatient waiting for a large 
object.

Ugh,

		Linus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help