Fix allocation check to test the right variable
authorDaniel Gustafsson
Tue, 17 Jun 2025 20:42:38 +0000 (22:42 +0200)
committerDaniel Gustafsson
Tue, 17 Jun 2025 20:42:38 +0000 (22:42 +0200)
commit917c00d761fa9ba3b2bc365804ef38fc60ec023e
tree2f433ee0419c2821858ceaa05a6840b26a012373
parent0cf205e122ae0fe9333ccf843c2269f13ddc32fc
Fix allocation check to test the right variable

The memory allocation for cancelConn->be_cancel_key was accidentally
checking the be_cancel_key member in the conn object instead of the
one in cancelConn.

Author: Ranier Vilela 
Reviewed-by: Daniel Gustafsson
Discussion: https://postgr.es/m/CAEudQAq4ySDR6dsg9xwurBXwud02hX7XCOZZAcZx-JMn6A06nA@mail.gmail.com
src/interfaces/libpq/fe-cancel.c