From daa8ed9274d91a157dc049f00792f62c98b0a11a Mon Sep 17 00:00:00 2001 From: Michael Brown Date: Wed, 16 Nov 2016 22:22:13 +0000 Subject: [interface] Provide intf_reinit() to reinitialise nullified interfaces Provide an abstraction intf_reinit() to restore the descriptor of a previously nullified interface. Signed-off-by: Michael Brown --- src/net/tcp/httpcore.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/net') diff --git a/src/net/tcp/httpcore.c b/src/net/tcp/httpcore.c index b1f74bc4f..27cc50653 100644 --- a/src/net/tcp/httpcore.c +++ b/src/net/tcp/httpcore.c @@ -787,12 +787,9 @@ static int http_transfer_complete ( struct http_transaction *http ) { /* Restart content decoding interfaces (which may be attached * to the same object). */ - intf_nullify ( &http->content ); - intf_nullify ( &http->transfer ); + intf_nullify ( &http->transfer ); /* avoid potential loops */ intf_restart ( &http->content, http->response.rc ); intf_restart ( &http->transfer, http->response.rc ); - http->content.desc = &http_content_desc; - http->transfer.desc = &http_transfer_desc; intf_plug_plug ( &http->transfer, &http->content ); http->len = 0; assert ( http->remaining == 0 ); -- cgit v1.2.3-55-g7522