Test that closing the socket immediately after sending write data causes an error

This commit is contained in:
Alex Young
2012-07-03 15:33:00 +01:00
parent d16aebf36e
commit 5c66d35677
3 changed files with 46 additions and 1 deletions

View File

@@ -40,6 +40,10 @@ module FlexNBD
@sock.write( [len ].pack( 'N' ) )
end
def write_data( data )
@sock.write( data )
end
def read_response
magic = @sock.read(4)