Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:10404 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 76497 invoked by uid 1010); 11 Jun 2004 15:00:29 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 76472 invoked from network); 11 Jun 2004 15:00:29 -0000 Received: from unknown (HELO jdi.jdimedia.nl) (212.204.192.51) by pb1.pair.com with SMTP; 11 Jun 2004 15:00:29 -0000 Received: from localhost (localhost [127.0.0.1]) by jdi.jdimedia.nl (8.12.10/8.12.10) with ESMTP id i5BF0RH2026095; Fri, 11 Jun 2004 17:00:28 +0200 Date: Fri, 11 Jun 2004 17:00:03 +0200 (CEST) X-X-Sender: derick@localhost To: Alexander Valyalkin cc: internals@lists.php.net In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Re: [PHP-DEV] str_repeat() patch From: derick@php.net (Derick Rethans) On Fri, 11 Jun 2004, Alexander Valyalkin wrote: > > Read it: > void *memmove(void *s1, const void *s2, size_t n); > If s1 and s2 overlap, all bytes are copied in a preserving manner (unlike > memcpy()) > > And anwer the question: are s1 and s2 overlap in the str_repeat() ? > Why don't use memcpy() instead of memmove() ? Because it's slower and we're copying to newly allocated memory anyway so things CAN not overlap. Also, your patch is the wrong way around. Please stop wasting our time with those silly patches that fix nothing; there is plenty of other good things to do to help with PHP development (like translations as Antony mentioned). regards, Derick