From owner-svn-src-all@freebsd.org Thu Jan 5 07:26:22 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C0463CA03F0; Thu, 5 Jan 2017 07:26:22 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x242.google.com (mail-pg0-x242.google.com [IPv6:2607:f8b0:400e:c05::242]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 834811865; Thu, 5 Jan 2017 07:26:22 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x242.google.com with SMTP id 75so1597637pgf.3; Wed, 04 Jan 2017 23:26:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=Av1ujPc/VAp6VJo/earytoUbaJpcqsTwDwmv6siuq7o=; b=E5WzOr1cv9ptdllvqKMH00JtS0sdaKwqs7vq37omHZvsVjhl2WPVGu4YKfChBN6cK4 ZCXsG44jflOe0XDqXUTWbNr9n94Z3UtT5Y5u+qZ7p/PGVwj3bylS6KJK4GAmEtfmNfXk gIDFxj3eyv69lObOZFj1nXqselQg8mBqgwGuEStoYhJZTjeBgg2mxByyKiq4xFtjU7OR wFTRRWGQaGTsnxN5Io72WRvuyxx+B7IAECI2H3CDn+KfRiI9g+0gm34cVdv1fuiY5Upa va1qp68S9jRg+wKp+TXutAtUEq6Imqum5g+CpFhbpjDhEoWFe06bULYQWPCMrVVZH3ns ya0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=Av1ujPc/VAp6VJo/earytoUbaJpcqsTwDwmv6siuq7o=; b=YXaNqXHsrtAjK2+KBMC0ags8ODahtLJcYslpa4j3m3OUUugl8Jjgeb1pFZ6WeYLhA5 HCN4Pb84xmCGMCUy5ZNgXuRP6t/INkfa0C4cAKHrhBIvJvmcSUnYERasDoZokBslmeud Y1UROO4L5KOlNUtWIeQuKgRZds25FKMxa7zWJnymOTyitsHIN/VyAxFVPO66mitH0ygq WcGdbJKr0sZO8lfa9IpgEqJRJxVyqaMdX/CVTQ4gB1BZgN9VdaujUh4d8M0ru/Z980VG lLvl0itfSotdcA4Buhh/4Y4wBzAKKBYBU8GWf/n/0bAFiHvDAOr4Ud1aERbgqG4Xd0Ps I8xw== X-Gm-Message-State: AIkVDXJyVzU8rFMJm4P1FW1UzrMQYBFjPWSZ7rJ8Q2SrI1yf9SGzxvpNsU84kO+1vj+n3A== X-Received: by 10.99.19.65 with SMTP id 1mr72343447pgt.153.1483601181615; Wed, 04 Jan 2017 23:26:21 -0800 (PST) Received: from [192.168.20.12] (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id 72sm151417161pfw.37.2017.01.04.23.26.20 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 04 Jan 2017 23:26:20 -0800 (PST) Subject: Re: svn commit: r311233 - head/contrib/netbsd-tests/fs/tmpfs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_E8D1BBDA-0DF9-4ADF-AB26-B81705D26167"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: Date: Wed, 4 Jan 2017 23:26:18 -0800 Cc: Jilles Tjoelker , Ngie Cooper , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201701040246.v042kaEh039041@repo.freebsd.org> <20170104233650.GB17765@stack.nl> To: Juli Mallett X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jan 2017 07:26:22 -0000 --Apple-Mail=_E8D1BBDA-0DF9-4ADF-AB26-B81705D26167 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Jan 4, 2017, at 22:29, Ngie Cooper wrote: >=20 >=20 >> On Jan 4, 2017, at 15:45, Juli Mallett = wrote: >>=20 >>> On Wed, Jan 4, 2017 at 3:36 PM, Jilles Tjoelker = wrote: >>>> On Wed, Jan 04, 2017 at 02:46:36AM +0000, Ngie Cooper wrote: >>>> - Initialize .sun_len before passing it to strlcpy and bind. >>> It would be better to avoid naming the non-portable sun_len field if = it >>> is just to make Coverity happy. I suggest initializing the structure >>> with designated initializers or memset(). >>>=20 >>> Apart from that, the value for sun_len is wrong; it should be the = length >>> of the whole structure and not just the sun_path part. Fortunately, = the >>> field is ignored by bind(), which uses the addrlen parameter = instead. >=20 > The problem was the strcpy and the fact that the code didn't check the = input buffer to make sure it didn't overrun the destination buffer. Bah.. I misremembered the fact that it was using strlcpy before and = after=E2=80=A6 -Ngie --Apple-Mail=_E8D1BBDA-0DF9-4ADF-AB26-B81705D26167 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYbfUbAAoJEPWDqSZpMIYVMSgP/Rf3U+6Vwlhw0nRbXdH+9RF+ sVG1H+Vz6K0+EEAaPPYCJi6HcXjXklsURhYxDuGtJaq0Hxz2peGXScPxjsaIOchP 7mSOFxX15cFz9jwaTaXaj0FyYQ1pFjmx7jmH49De2Pmu9/E5xBCZDPa1J7Leet4C bdvC9AX/U+/M/UPpgude6yOM73Xpo65LO+DjgCLLhkPj72Ij7tyc0kankLyCLK1h zZGf0Hyb/l+WS7JCOYCKhFSxIS0XisGs+foYZ1JJc/kzitgdxVtOyqhjYrQy8OW4 7RZYaUMjzZUIYernyTwY2eTikG7Zvi+2KlJWV1V8ppIfCF9pwvlYBL31CwcAobHr DRci90y79aGrQWvG/bnmqfs52XQo2EVt190u1sqLT/nmpBvZBnTfXKeoTHDRKZxA p8HJJKdLTyrR/oj3gB4L+bvD+dAGZjZYbGitvUTzkmMiRHgauc2eORlxXPL8TpN7 pNdHQzq4GXV8dyLPIjDp6Zj39cieqz8oFXtVw8NR6+hk9xXA1fGhkdrMyJxli/on l7qAaThoosg8i+e3L45iK1bS+AtJTDGevmo6W0rWq2V3k+qNKekA+PrVzP9d7ciw 5/kRLJNFp+s+d//yc6BTM3uk+VteosBDT72cGvbJxxCbbnhCcCRvryqilwwwROmK Zgu/SfLbWOelMx+wg5bI =nO3T -----END PGP SIGNATURE----- --Apple-Mail=_E8D1BBDA-0DF9-4ADF-AB26-B81705D26167--