Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:54362 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 27528 invoked from network); 4 Aug 2011 15:39:39 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Aug 2011 15:39:39 -0000 Authentication-Results: pb1.pair.com smtp.mail=pierre.php@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=pierre.php@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.218.42 as permitted sender) X-PHP-List-Original-Sender: pierre.php@gmail.com X-Host-Fingerprint: 209.85.218.42 mail-yi0-f42.google.com Received: from [209.85.218.42] ([209.85.218.42:43739] helo=mail-yi0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 25/50-25862-A3DBA3E4 for ; Thu, 04 Aug 2011 11:39:38 -0400 Received: by yih10 with SMTP id 10so1274307yih.29 for ; Thu, 04 Aug 2011 08:39:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=V5YSNqXBwCEp5iqdR7uldib6b6ef1I47bHw94JdHkIM=; b=OEKoeKPWIi1c5klf/vEihyS9HVr7xW3/PEFfsTNRmgXm4bx6BkSo0zDf93cpalLw/Z V37wDMiMZsRAi+sOmUnbTh2VgvwnpI5Mf8G+7vPMaY1NlopeJQA4IgVEHYIe4eukQ4GR U46vcSmsCCdiZeV4PWaXD/V9vwxz6vAlsMFjQ= MIME-Version: 1.0 Received: by 10.236.182.33 with SMTP id n21mr1280422yhm.47.1312472376137; Thu, 04 Aug 2011 08:39:36 -0700 (PDT) Received: by 10.147.169.17 with HTTP; Thu, 4 Aug 2011 08:39:36 -0700 (PDT) In-Reply-To: References: Date: Thu, 4 Aug 2011 17:39:36 +0200 Message-ID: To: Keloran Cc: PHP Internals Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] [PATCH] fix imap_mail actually use the rpath option From: pierre.php@gmail.com (Pierre Joye) hi, Can you attach this patch to the bug please? Thanks for your work! On Thu, Aug 4, 2011 at 5:30 PM, Keloran wrote: > Index: ext/imap/php_imap.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- ext/imap/php_imap.c (revision 314217) > +++ ext/imap/php_imap.c (working copy) > @@ -4016,7 +4016,27 @@ > =A0 =A0 =A0 =A0if (!INI_STR("sendmail_path")) { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0return 0; > =A0 =A0 =A0 =A0} > - =A0 =A0 =A0 sendmail =3D popen(INI_STR("sendmail_path"), "w"); > + > + =A0 =A0 =A0 /** Used to make return-path work **/ > + =A0 =A0 =A0 =A0char *sendmail_path =3D INI_STR("sendmail_path"); > + =A0 =A0 =A0 =A0char *appended_sendmail_path =3D NULL; > + > + =A0 =A0 =A0 =A0/** Return Path or not **/ > + =A0 =A0 =A0 =A0if (rpath && rpath[0]) { > + =A0 =A0 =A0 =A0 =A0 =A0appended_sendmail_path =3D emalloc( > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0strlen(sendmail_path) + 3 + strlen(rpath= ) + 1); > + =A0 =A0 =A0 =A0 =A0 =A0strcpy(appended_sendmail_path, sendmail_path); > + =A0 =A0 =A0 =A0 =A0 =A0strcat(appended_sendmail_path, " -f"); > + =A0 =A0 =A0 =A0 =A0 =A0strcat(appended_sendmail_path, rpath); > + =A0 =A0 =A0 =A0 =A0 =A0sendmail_path =3D appended_sendmail_path; > + =A0 =A0 =A0 =A0} > + > + =A0 =A0 =A0 =A0/** open the sendmail pointer **/ > + =A0 =A0 =A0 =A0sendmail =3D popen(sendmail_path, "w"); /* New Code */ > + > + =A0 =A0 =A0 if (appended_sendmail_path) > + =A0 =A0 =A0 =A0 =A0 =A0efree(appended_sendmail_path); > + > =A0 =A0 =A0 =A0if (sendmail) { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (rpath && rpath[0]) fprintf(sendmail, "= From: %s\n", > rpath); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0fprintf(sendmail, "To: %s\n", to); > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > hopefully that will work to fix the rpath option, and finally close this > bug http://bugs.php.net/bug.php?id=3D30688 > --=20 Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org