|
10 | 10 | * Written by Peter Eisentraut <peter_e@gmx.net>.
|
11 | 11 | *
|
12 | 12 | * IDENTIFICATION
|
13 |
| - * $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.472 2008/09/10 19:16:22 tgl Exp $ |
| 13 | + * $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.473 2008/09/23 21:12:03 mha Exp $ |
14 | 14 | *
|
15 | 15 | *--------------------------------------------------------------------
|
16 | 16 | */
|
@@ -6176,8 +6176,12 @@ GetConfigOptionByNum(int varnum, const char **values, bool *noshow)
|
6176 | 6176 | break;
|
6177 | 6177 | }
|
6178 | 6178 |
|
6179 |
| -/* If the setting came from a config file, set the source location */ |
6180 |
| -if (conf->source==PGC_S_FILE) |
| 6179 | +/* |
| 6180 | + * If the setting came from a config file, set the source location. |
| 6181 | + * For security reasons, we don't show source file/line number for |
| 6182 | + * non-superusers. |
| 6183 | + */ |
| 6184 | +if (conf->source==PGC_S_FILE&&superuser()) |
6181 | 6185 | {
|
6182 | 6186 | values[12]=conf->sourcefile;
|
6183 | 6187 | snprintf(buffer,sizeof(buffer),"%d",conf->sourceline);
|
|