Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:44446 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 45790 invoked from network); 23 Jun 2009 19:57:40 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 23 Jun 2009 19:57:40 -0000 Authentication-Results: pb1.pair.com smtp.mail=gwynne@darkrainfall.org; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=gwynne@darkrainfall.org; sender-id=unknown Received-SPF: error (pb1.pair.com: domain darkrainfall.org from 208.97.132.119 cause and error) X-PHP-List-Original-Sender: gwynne@darkrainfall.org X-Host-Fingerprint: 208.97.132.119 balanced.mail.policyd.dreamhost.com Received: from [208.97.132.119] ([208.97.132.119:51092] helo=homiemail-a4.g.dreamhost.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 53/BF-36467-2B3314A4 for ; Tue, 23 Jun 2009 15:57:39 -0400 Received: from Moonstar.home (pool-71-174-84-161.bstnma.fios.verizon.net [71.174.84.161]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by homiemail-a4.g.dreamhost.com (Postfix) with ESMTP id CE1364178D; Tue, 23 Jun 2009 12:57:34 -0700 (PDT) Cc: Hannes Magnusson , PHP Development Message-ID: <310F6EAF-6EB4-45D0-BAC4-437C9C764AD0@darkrainfall.org> To: =?UTF-8?Q?Johannes_Schl=C3=BCter?= In-Reply-To: <1245786546.3551.6.camel@goldfinger.johannes.nop> Content-Type: text/plain; charset=UTF-8; format=flowed; delsp=yes Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Apple Message framework v935.3) Date: Tue, 23 Jun 2009 15:57:33 -0400 References: <7f3ed2c30906230155j12d81566o9b4bee3fe7749e48@mail.gmail.com> <1245786546.3551.6.camel@goldfinger.johannes.nop> X-Mailer: Apple Mail (2.935.3) Subject: Re: [PHP-DEV] header_remove() issues (overly aggressive?) From: gwynne@darkrainfall.org (Gwynne Raskind) On Jun 23, 2009, at 3:49 PM, Johannes Schl=C3=BCter wrote: >> While documenting header_remove() I was experimenting a little bit.. >> >> If an "empty" argument is passed to the function (empty string, null, >> false,..) the function doesn't do anything, as it checks for >> ZEND_NUM_ARGS() rather then the length of string.. thats a doc issue >> or bug? > I'd say it's ok, "remove the header with the name ''." That's what it > does. A header named '' isn't valid in HTTP 1.0 or 1.1 anyway; this is an =20 error case IMO. >> Second, it removes even the X-Powered-By header, is that expected? Useful for people who don't have control over their expose_php =20 setting... >> Third, it removes session and even cookie headers.. > >> Is that really expected? Just add a big fat warning on the doc page? > It removes all. Should be ok, too, removing the session cookie might > even be considered a "good" feature by some. Including me! ;) -- Gwynne