Return-Path: X-Original-To: apmail-subversion-dev-archive@minotaur.apache.org Delivered-To: apmail-subversion-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 17DA7102BC for ; Mon, 12 Jan 2015 11:23:04 +0000 (UTC) Received: (qmail 95751 invoked by uid 500); 12 Jan 2015 11:23:04 -0000 Delivered-To: apmail-subversion-dev-archive@subversion.apache.org Received: (qmail 95702 invoked by uid 500); 12 Jan 2015 11:23:04 -0000 Mailing-List: contact dev-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list dev@subversion.apache.org Received: (qmail 94725 invoked by uid 99); 12 Jan 2015 11:23:03 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jan 2015 11:23:03 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of philip.martin@wandisco.com designates 74.125.82.52 as permitted sender) Received: from [74.125.82.52] (HELO mail-wg0-f52.google.com) (74.125.82.52) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jan 2015 11:22:58 +0000 Received: by mail-wg0-f52.google.com with SMTP id x12so18611175wgg.11 for ; Mon, 12 Jan 2015 03:22:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wandisco.com; s=gapps; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=4ZOoWe0AgwZTL6F/s/qEbwI7771kbR7MCsveobny/FU=; b=Bupqa0Yuc+sKYXFrQr8xm4nW1yvswwdLPypV4nHErdjnYJxcblJecUMhiRyzsHuIyn lNlrmfkPxKPdPVP2lDaOA2N5d4FVgbQeKglEHl3ECOQJWXyjtl5LsCGLvCWQsSYJmEa0 0EoeZ0TCw4Mdr8aDTgJEawtPJiY5UtYhp+etk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-type; bh=4ZOoWe0AgwZTL6F/s/qEbwI7771kbR7MCsveobny/FU=; b=bTMmsR5dH68o/UPBfXIHqI+P4upjIqeUiVJqr2dImyy8rOWca4Ea4rNSkzuWwrMk+P 9kjDKwv0mg07/oK4Ms46b4ofDH2KRocZhNKxDkER2lRUDJzeWP+TSq1LK6vtsOU5E1KY 9UH1Vp2KfqTSC4XWdxa2BrQWIGZDvxwQZmA7OpsmeuWEG/SLF6SXr0Rs7NF4AV6ydMsu I5q8ukdWmi7cPhmujhX1BqKNM+9ltUldMFFQNegisu6dSKvT4lfS7vUfNGk6LFeP45sP cjzLsX2GVVEfebA8vHqD8RLkTIJLdfHB+esQMcBbVtkj9P9Wh0UfRNu7q6yd5L1PONno 6OgQ== X-Gm-Message-State: ALoCoQk8HQeVAQVUJIWsFF+uSO/M1ke3y0MTxYFOrN9WjY/owHe2mUAMMFtjpZKGN/NwoG+Ce0A8 X-Received: by 10.194.94.1 with SMTP id cy1mr32103933wjb.127.1421061756313; Mon, 12 Jan 2015 03:22:36 -0800 (PST) Received: from localhost (cpc20-farn7-2-0-cust13.6-2.cable.virginm.net. [86.15.228.14]) by mx.google.com with ESMTPSA id q7sm9816114wiv.8.2015.01.12.03.22.35 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 12 Jan 2015 03:22:35 -0800 (PST) From: Philip Martin To: Lieven Govaerts Cc: "serf-dev\@googlegroups.com" , pierre.viret@postfinance.ch, Subversion Development Subject: Re: [serf-dev] Re: [PATCH] Serf crash on spurious data between responses References: <1434486319.700608.1420529505682.JavaMail.postmaster@post.ch> <878uhgb03r.fsf@ntlworld.com> <1332240118.440483.1420549488045.JavaMail.postmaster@post.ch> <87y4pg9fe7.fsf@ntlworld.com> <2123531229.447826.1420556241367.JavaMail.postmaster@post.ch> <87h9w2d7ic.fsf@ntlworld.com> <472712693.57162.1420703794232.JavaMail.postmaster@post.ch> <87ioghxuqb.fsf@ntlworld.com> <87a91txmp8.fsf@ntlworld.com> <8761chxjhu.fsf@ntlworld.com> <87y4pdw3nc.fsf_-_@ntlworld.com> <87d26n8r43.fsf_-_@ntlworld.com> <87r3v2260i.fsf@ntlworld.com> Date: Mon, 12 Jan 2015 11:22:34 +0000 In-Reply-To: (Lieven Govaerts's message of "Mon, 12 Jan 2015 11:41:06 +0100") Message-ID: <87oaq4ckg5.fsf@ntlworld.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.4 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Checked: Checked by ClamAV on apache.org Lieven Govaerts writes: > You're trying to capture the situation where serf has: > - finished writing a request ( req_bkt == NULL && writing_started ) > - has no more requests in the pending queue > - and receives actual bytes of data. > Right? > > Looks like your patch is a correct way to fix the problem. Some > comments would be welcome, and if you have the time a test. I'm not familiar with serf's testsuite. The scenario: - client sends first request - server sends response - server sends extra data, say '\n' - client handles first request - client creates a second request - client calls serf to send second, pipelined, request - serf reads extra data - serf attempts to pass the extra data to client's callbacks At this point serf has not called setup_request so although the client has created a request is not ready to receive data. How do I go about writing such a test? -- Philip Martin | Subversion Committer WANdisco // *Non-Stop Data*