git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a6d3dea)
Initialize conn->Pfdebug to NULL when creating a connection
2021年3月31日 22:16:58 +0000 (19:16 -0300)
2021年3月31日 22:19:57 +0000 (19:19 -0300)
Failing to do this can cause a crash, and I suspect is what has happened
with a buildfarm member reporting mysterious failures.

This is an ancient bug, but I'm not backpatching since evidently nobody
cares about PQtrace in older releases.

Discussion: https://postgr.es/m/3333908.1617227066@sss.pgh.pa.us


diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index a90bdb8ab6d6e83c086e6b0aa2ab65b8b20db482..56a8266bc3fc0a58c1e3fbeb45c142a57b2869c1 100644 (file)
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -3952,6 +3952,7 @@ makeEmptyPGconn(void)
conn->verbosity = PQERRORS_DEFAULT;
conn->show_context = PQSHOW_CONTEXT_ERRORS;
conn->sock = PGINVALID_SOCKET;
+ conn->Pfdebug = NULL;
/*
* We try to send at least 8K at a time, which is the usual size of pipe
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /