Skip to content

Commit 2e0e563

Browse files
committed
Avoid trying to print a NULL char pointer in --describe-config. On some
platforms this works, but on some it crashes. Zdenek Kotala
1 parent 9713c06 commit 2e0e563

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/backend/utils/misc/help_config.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/backend/utils/misc/help_config.c,v 1.19 2008/01/01 19:45:54 momjian Exp $
13+
* $PostgreSQL: pgsql/src/backend/utils/misc/help_config.c,v 1.20 2008/02/23 19:23:33 tgl Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -117,7 +117,7 @@ printMixedStruct(mixedStruct *structToPrint)
117117

118118
case PGC_STRING:
119119
printf("STRING\t%s\t\t\t",
120-
structToPrint->string.boot_val);
120+
structToPrint->string.boot_val ? structToPrint->string.boot_val : "");
121121
break;
122122

123123
default:

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