Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e1gRZ-0005Vy-P7 for pgsql-committers@arkaria.postgresql.org; Mon, 09 Oct 2017 22:22:37 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1e1gRZ-0004bb-Bd for pgsql-committers@arkaria.postgresql.org; Mon, 09 Oct 2017 22:22:37 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e1gRD-0002As-PO for pgsql-committers@postgresql.org; Mon, 09 Oct 2017 22:22:15 +0000 Received: from mahout.postgresql.org ([2001:4800:1501:1::227]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e1gR6-0000zQ-3e for pgsql-committers@postgresql.org; Mon, 09 Oct 2017 22:22:15 +0000 Received: from gemulon.postgresql.org ([2001:4800:1501:1::198]) by mahout.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1e1gR3-0001HO-JF for pgsql-committers@postgresql.org; Mon, 09 Oct 2017 22:22:06 +0000 Received: from git by gemulon.postgresql.org with local (Exim 4.84_2) (envelope-from ) id 1e1gR2-0005fC-SP for pgsql-committers@postgresql.org; Mon, 09 Oct 2017 22:22:04 +0000 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 To: pgsql-committers@postgresql.org From: Andres Freund Subject: pgsql: Fix pnstrdup() to not memcpy() the maximum allowed length. Message-Id: Date: Mon, 09 Oct 2017 22:22:04 +0000 List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-committers Precedence: bulk Sender: pgsql-committers-owner@postgresql.org Rml4IHBuc3RyZHVwKCkgdG8gbm90IG1lbWNweSgpIHRoZSBtYXhpbXVtIGFs bG93ZWQgbGVuZ3RoLgoKVGhlIHByZXZpb3VzIGJlaGF2aW91ciB3YXMgZGFu Z2Vyb3VzIGlmIHRoZSBsZW5ndGggcGFzc2VkIHdhc24ndCB0aGUKc2l6ZSBv ZiB0aGUgdW5kZXJseWluZyBidWZmZXIsIGJ1dCB0aGUgbWF4aW11bSBzaXpl IG9mIHRoZSB1bmRlcmx5aW5nCmJ1ZmZlci4KCkF1dGhvcjogQW5kcmVzIEZy ZXVuZApEaXNjdXNzaW9uOiBodHRwczovL3Bvc3Rnci5lcy9tLzIwMTYxMDAz MjE1NTI0Lm13ejVwNDVwY3ZlcnJreWtAYWxhcDMuYW5hcmF6ZWwuZGUKCkJy YW5jaAotLS0tLS0KbWFzdGVyCgpEZXRhaWxzCi0tLS0tLS0KaHR0cHM6Ly9n aXQucG9zdGdyZXNxbC5vcmcvcGcvY29tbWl0ZGlmZi84MmMxMTdjYjkwZTZi NmI3OWYwNmQ2MWViMWRkZjA2ZTk0ZTc1YjYwCgpNb2RpZmllZCBGaWxlcwot LS0tLS0tLS0tLS0tLQpzcmMvYmFja2VuZC91dGlscy9tbWdyL21jeHQuYyB8 IDcgKysrKysrLQoxIGZpbGUgY2hhbmdlZCwgNiBpbnNlcnRpb25zKCspLCAx IGRlbGV0aW9uKC0pCgoKLS0gClNlbnQgdmlhIHBnc3FsLWNvbW1pdHRlcnMg bWFpbGluZyBsaXN0IChwZ3NxbC1jb21taXR0ZXJzQHBvc3RncmVzcWwub3Jn KQpUbyBtYWtlIGNoYW5nZXMgdG8geW91ciBzdWJzY3JpcHRpb246Cmh0dHA6 Ly93d3cucG9zdGdyZXNxbC5vcmcvbWFpbHByZWYvcGdzcWwtY29tbWl0dGVy cwo=