From owner-freebsd-net@FreeBSD.ORG Thu Sep 18 07:56:12 2008 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A66471065672 for ; Thu, 18 Sep 2008 07:56:12 +0000 (UTC) (envelope-from alexander@leidinger.net) Received: from redbull.bpaserver.net (redbullneu.bpaserver.net [213.198.78.217]) by mx1.freebsd.org (Postfix) with ESMTP id 592178FC16 for ; Thu, 18 Sep 2008 07:56:07 +0000 (UTC) (envelope-from alexander@leidinger.net) Received: from outgoing.leidinger.net (p5DC5F32C.dip.t-dialin.net [93.197.243.44]) by redbull.bpaserver.net (Postfix) with ESMTP id 9EA322E1F9; Thu, 18 Sep 2008 09:38:34 +0200 (CEST) Received: from webmail.leidinger.net (webmail.leidinger.net [192.168.1.102]) by outgoing.leidinger.net (Postfix) with ESMTP id 101AF155369; Thu, 18 Sep 2008 09:38:32 +0200 (CEST) Received: (from www@localhost) by webmail.leidinger.net (8.14.2/8.13.8/Submit) id m8I7cVhC026284; Thu, 18 Sep 2008 09:38:31 +0200 (CEST) (envelope-from Alexander@Leidinger.net) Received: from pslux.cec.eu.int (pslux.cec.eu.int [158.169.9.14]) by webmail.leidinger.net (Horde Framework) with HTTP; Thu, 18 Sep 2008 09:38:31 +0200 Message-ID: <20080918093831.89545e2iu5zjgjgg@webmail.leidinger.net> X-Priority: 3 (Normal) Date: Thu, 18 Sep 2008 09:38:31 +0200 From: "Alexander Leidinger" To: "Chagin Dmitry" References: <20080822112927.GZ99951@hoeg.nl> <20080822112946.GA97526@freebsd.org> <20080831110610.GA2380@dchagin.dialup.corbina.ru> <20080902085623.GA12395@freebsd.org> <20080917183801.GA2714@dchagin.dialup.corbina.ru> <20080917190230.GA2947@dchagin.dialup.corbina.ru> In-Reply-To: <20080917190230.GA2947@dchagin.dialup.corbina.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable User-Agent: Internet Messaging Program (IMP) H3 (4.2) / FreeBSD-8.0 X-BPAnet-MailScanner-Information: Please contact the ISP for more information X-MailScanner-ID: 9EA322E1F9.2187C X-BPAnet-MailScanner: Found to be clean X-BPAnet-MailScanner-SpamCheck: not spam, ORDB-RBL, SpamAssassin (not cached, score=-14.7, required 6, BAYES_00 -15.00, MR_NOT_ATTRIBUTED_IP 0.20, RDNS_DYNAMIC 0.10) X-BPAnet-MailScanner-From: alexander@leidinger.net X-Spam-Status: No Cc: freebsd-net@freebsd.org, freebsd-emulation@freebsd.org Subject: Re: [PATCH] recvmsg() sendmsg() linux emulation X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Sep 2008 07:56:12 -0000 Quoting "Chagin Dmitry" (from Wed, 17 Sep 2008 =20 23:02:30 +0400): > On Wed, Sep 17, 2008 at 10:38:01PM +0400, Chagin Dmitry wrote: >> >> Please review, any comment will be helpful. I did just a very quick look... > @@ -978,9 +1072,13 @@ linux_sendmsg(struct thread *td, struct =20 > linux_sendmsg_args *args) > =09 */ > =09if (msg.msg_control !=3D NULL && msg.msg_controllen =3D=3D 0) > =09=09msg.msg_control =3D NULL; > + > +#if defined(__amd64__) && defined(COMPAT_LINUX32) > +=09error =3D linux32_copyiniov(PTRIN(msg.msg_iov), msg.msg_iovlen, > +=09 &iov, EMSGSIZE); > +#else > =09error =3D copyiniov(msg.msg_iov, msg.msg_iovlen, &iov, EMSGSIZE); > -=09if (error) > -=09=09return (error); > +#endif > =09msg.msg_iov =3D iov; > =09msg.msg_flags =3D 0; > =09error =3D linux_sendit(td, args->s, &msg, args->flags, UIO_USERSPACE); You've lost the error handling in the conditional. Bye, Alexander. --=20 BOFH excuse #266: All of the packets are empty http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID =3D B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID =3D 72077137