8000 There is a bug in aclitemout which causes a notice to be sent to the … · home201448/postgres@3208b4d · GitHub
[go: up one dir, main page]

Skip to content

Commit 3208b4d

Browse files
committed
There is a bug in aclitemout which causes a notice to be sent to the client
while the backend is trying to pfree a string not allocated with palloc. Submitted by: Massimo Dal Zotto <dz@cs.unitn.it>
1 parent ba30435 commit 3208b4d

File tree

1 file changed

+5
-1
lines changed
  • src/backend/utils/adt

1 file changed

+5
-1
lines changed

src/backend/utils/adt/acl.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.1.1.1 1996/07/09 06:22:02 scrappy Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.1.1.1.2.1 1996/10/11 03:15:38 scrappy Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -258,7 +258,11 @@ aclitemout(AclItem *aip)
258258
(void) strcat(p, "group ");
259259
tmpname = get_groname(aip->ai_id);
260260
(void) strncat(p, tmpname, NAMEDATALEN);
261+
#ifdef ACL_PATCH
262+
/* tmpname is a pointer into tuple data, don't pfree it */
263+
#else
261264
pfree(tmpname);
265+
#endif
262266
break;
263267
case ACL_IDTYPE_WORLD:
264268
break;

0 commit comments

Comments
 (0)
0