Skip to content

Commit e3285f3

Browse files
committed
Update PQfree() documentation to be clearer, backpatch to 8.2.X.
1 parent 4acc4aa commit e3285f3

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

doc/src/sgml/libpq.sgml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/libpq.sgml,v 1.231 2007/02/16 16:37:29 tgl Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/libpq.sgml,v 1.232 2007/02/19 22:06:23 momjian Exp $ -->
22

33
<chapter id="libpq">
44
<title><application>libpq</application> - C Library</title>
@@ -2617,9 +2617,13 @@ void PQfreemem(void *ptr);
26172617
<function>PQescapeBytea</function>,
26182618
<function>PQunescapeBytea</function>,
26192619
and <function>PQnotifies</function>.
2620-
It is needed by Microsoft Windows, which cannot free memory across
2621-
DLLs, unless multithreaded DLLs (<option>/MD</option> in VC6) are used.
2622-
On other platforms, this function is the same as the standard library function <function>free()</>.
2620+
It is particularly important that this function, rather than
2621+
<function>free()</>, be used on Microsoft Windows. This is because
2622+
allocating memory in a DLL and releasing it in the application works
2623+
only if multithreaded/single-threaded, release/debug, and static/dynamic
2624+
flags are the same for the DLL and the application. On non-Microsoft
2625+
Windows platforms, this function is the same as the standard library
2626+
function <function>free()</>.
26232627
</para>
26242628
</listitem>
26252629
</varlistentry>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy