Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68018 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 80558 invoked from network); 29 Jun 2013 09:25:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 29 Jun 2013 09:25:55 -0000 Authentication-Results: pb1.pair.com header.from=nikita.ppv@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=nikita.ppv@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.219.44 as permitted sender) X-PHP-List-Original-Sender: nikita.ppv@gmail.com X-Host-Fingerprint: 209.85.219.44 mail-oa0-f44.google.com Received: from [209.85.219.44] ([209.85.219.44:52421] helo=mail-oa0-f44.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 81/86-37409-228AEC15 for ; Sat, 29 Jun 2013 05:25:55 -0400 Received: by mail-oa0-f44.google.com with SMTP id l10so3266459oag.3 for ; Sat, 29 Jun 2013 02:25:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=yNM+ocULVhuYmI+VI6d6KKOaEb1zm0lfIeiGVPpZtG4=; b=rtoGMVa+JmLQVgoLnG3Q5B2P1fqfK/xJDZS8wIcM/V6PQyHYdlXZq0ecIWwxOu5mbS bX6Jhau1KvBNJlB/AwWJJXqfZnaszQ69+xX/FyC4mNBe6I0X1L52RL6A1hdd4hiRl8hs o5WvozqUNHt3qwx/lRH1JGEDh7atnbjYkRlQQhYUbwrUtAHiqQOL6Oo+fHiDyXBfr0I0 EaGJhX3kYNL8Yg5sCMuwTyBn2WwlAkwOLeKddf6BcFtYX01LDPhVE0f9hDdyzYv+IRCc Wl2eDvLA0BC7z5s0HNB1hK3Sj2MoJzrLIVfAf/mkymhesv0ZBo1fO/z2HAls0HzV4XHW fqWA== MIME-Version: 1.0 X-Received: by 10.60.99.101 with SMTP id ep5mr6725033oeb.98.1372497952187; Sat, 29 Jun 2013 02:25:52 -0700 (PDT) Received: by 10.182.89.170 with HTTP; Sat, 29 Jun 2013 02:25:52 -0700 (PDT) In-Reply-To: References: <51CD5580.50103@gmail.com> Date: Sat, 29 Jun 2013 11:25:52 +0200 Message-ID: To: Yasuo Ohgaki Cc: Sherif Ramadan , =?ISO-8859-2?Q?Leszek_Krupi=F1ski?= , PHP Internals Content-Type: multipart/alternative; boundary=047d7b33d0f0e529d504e04794be Subject: Re: [PHP-DEV] Re: hex2bin: E_WARNING is too much for odd string? From: nikita.ppv@gmail.com (Nikita Popov) --047d7b33d0f0e529d504e04794be Content-Type: text/plain; charset=ISO-8859-1 On Sat, Jun 29, 2013 at 3:41 AM, Yasuo Ohgaki wrote: > Hi Sherif, > > The problem is that current code 'returns false for invalid hex' while it > 'returns false and E_WARNING for invalid length'. > > We may choose behavior for invalid inputs > - return false always > - return false and raise E_WARNING always > For the record, I'm okay with having E_WARNING in both cases. Nikita --047d7b33d0f0e529d504e04794be--