Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WBq5o-0007U2-Fw for pgsql-bugs@arkaria.postgresql.org; Fri, 07 Feb 2014 18:24:00 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WBq5n-0005wY-Mq for pgsql-bugs@arkaria.postgresql.org; Fri, 07 Feb 2014 18:23:59 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WBq5l-0005wP-Pt for pgsql-bugs@postgresql.org; Fri, 07 Feb 2014 18:23:57 +0000 Received: from mail-pb0-f52.google.com ([209.85.160.52]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WBq5e-0000kt-Il for pgsql-bugs@postgresql.org; Fri, 07 Feb 2014 18:23:57 +0000 Received: by mail-pb0-f52.google.com with SMTP id jt11so3585978pbb.25 for ; Fri, 07 Feb 2014 10:23:48 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:subject:from:to:date:content-type :mime-version; bh=Lb77o2jGm5SMxEQDVQNdp0eZOse44HcAzCyaQ4pY540=; b=FMJINVVkIX0uVGHBMY5AJ9lwJycKNFFcq9M+7lhwdXQ8fggzyQwckGo+cxxlctPioB z7JYHrUwOM/MLqZYVY8RAI/mT+czBfMlh+JtM/zRVyLdOCArd/Iyn9L1k3j76FKwqRen b4wddcd4lrAnAOzecqiRo95gd/MGHUIL2RU4dRkCwgVkPfaZeM0xAhw6hb3wRuM/R8Xs W7UQCHYVqG4lqq7dmJvfamA9Ts7qVlPQGgDqG7rjf8TNzQPX3mG3Nrg5Qu/txw6yJ8om dlyCZ2TmPlVsr/lOKL2QVQnmrT+IsDKsFT3U6tWkfPPAimLayctDmdAXtwvaiuuMkuSf NDmA== X-Gm-Message-State: ALoCoQlpy9LnhXTSWIvOB21BLMUdgICAUcsyXw8+Hz8Tfep1fM0dVdcPtqFC4Ox1YUZ+tOqnmNQt X-Received: by 10.66.26.236 with SMTP id o12mr9801534pag.15.1391797428205; Fri, 07 Feb 2014 10:23:48 -0800 (PST) Received: from [192.168.0.106] (c-69-181-249-16.hsd1.ca.comcast.net. [69.181.249.16]) by mx.google.com with ESMTPSA id nu10sm15908480pbb.16.2014.02.07.10.23.46 for (version=SSLv3 cipher=RC4-SHA bits=128/128); Fri, 07 Feb 2014 10:23:46 -0800 (PST) Message-ID: <1391797441.15160.41.camel@jdavis> Subject: Crash in json_to_record() From: Jeff Davis To: pgsql-bugs@postgresql.org Date: Fri, 07 Feb 2014 10:24:01 -0800 Content-Type: multipart/mixed; boundary="=-HHE2GQgkD/19l1JdtT5m" X-Mailer: Evolution 3.8.4-0ubuntu1 Mime-Version: 1.0 X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org --=-HHE2GQgkD/19l1JdtT5m Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit The attached script crashes on master. It looks like it assumes get_call_result_type() always returns a non-NULL tupdesc. Regards, Jeff Davis --=-HHE2GQgkD/19l1JdtT5m Content-Disposition: attachment; filename="crash.sql" Content-Type: text/x-sql; name="crash.sql"; charset="UTF-8" Content-Transfer-Encoding: 7bit drop table t; create table t(j json); insert into t values('{"a": 1, "b": "two", "c": [1,2,3], "d": {"x": "X", "y": "Y"}}'); select json_to_record(j, true) from t; --=-HHE2GQgkD/19l1JdtT5m Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs --=-HHE2GQgkD/19l1JdtT5m--