From 4fd1b141635cbb0db3d2f248d0508ec6920f6c8d Mon Sep 17 00:00:00 2001 From: florian Date: Fri, 18 Oct 2013 14:44:36 +0000 Subject: Calculate correct pointer for fcgi_{begin,end}_request_body. input / OK blambert --- slowcgi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'slowcgi.c') diff --git a/slowcgi.c b/slowcgi.c index a5128d4..2c5d767 100644 --- a/slowcgi.c +++ b/slowcgi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: slowcgi.c,v 1.13 2013/10/18 14:43:21 florian Exp $ */ +/* $OpenBSD: slowcgi.c,v 1.14 2013/10/18 14:44:36 florian Exp $ */ /* * Copyright (c) 2013 David Gwynne * Copyright (c) 2013 Florian Obser @@ -1012,10 +1012,10 @@ dump_fcgi_record(const char *p, struct fcgi_record_header *h) if (h->type == FCGI_BEGIN_REQUEST) dump_fcgi_begin_request_body(p, - (struct fcgi_begin_request_body *)((char *)h) + sizeof(*h)); + (struct fcgi_begin_request_body *)(h + 1)); else if (h->type == FCGI_END_REQUEST) dump_fcgi_end_request_body(p, - (struct fcgi_end_request_body *)((char *)h) + sizeof(*h)); + (struct fcgi_end_request_body *)(h + 1)); } void -- cgit v1.2.3-2-gb3c3