From: Tom Lane <tgl@sss.pgh.pa.us>
To: Pavel Stehule <pavel.stehule@gmail.com>
Cc: Jack Orenstein <jao@geophile.com>
Cc: " <pgsql-general@postgresql.org>
Subject: Re: Finding memory corruption in an extension
Date: Fri, 08 Jan 2021 13:28:45 -0500
Message-ID: <326715.1610130525@sss.pgh.pa.us> (raw)
In-Reply-To: <CAFj8pRCtUDQw5eNZ1DmUsYU1EfctcCf63A=pz0_RnJt975Qv9A@mail.gmail.com>
References: <CAGNxcavzErZhb+7h6O33wBJOo1qVhTYGNRyC-j3ZydDaQJOy7w@mail.gmail.com>
<CAFj8pRCtUDQw5eNZ1DmUsYU1EfctcCf63A=pz0_RnJt975Qv9A@mail.gmail.com>
Pavel Stehule <pavel.stehule@gmail.com> writes:
> pá 8. 1. 2021 v 18:48 odesílatel Jack Orenstein <jao@geophile.com> napsal:
>> I'm interested in advice on how to go about hunting down my problem.
>> Something along the lines of a debugging malloc, or valgrind, for Postgres.
> The basic feature is using postgres compiled with --enable-cassert flag. It
> does lot of checks of memory corruptions
Yeah, you should absolutely use --enable-cassert when working on C code.
If you need valgrind, there's advice about how to run it at
https://wiki.postgresql.org/wiki/Valgrind
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: tgl@sss.pgh.pa.us, pavel.stehule@gmail.com, jao@geophile.com
Subject: Re: Finding memory corruption in an extension
In-Reply-To: <326715.1610130525@sss.pgh.pa.us>
References: <CAGNxcavzErZhb+7h6O33wBJOo1qVhTYGNRyC-j3ZydDaQJOy7w@mail.gmail.com> <CAFj8pRCtUDQw5eNZ1DmUsYU1EfctcCf63A=pz0_RnJt975Qv9A@mail.gmail.com> <326715.1610130525@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox