read_conf_file ignores include_if_exists in config file
Bug #1098986 reported by
Myle Ott
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
postgresql-common (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
The read_conf_file function in PgCommon.pm (~line 108) will process external config files that are included with "include" but not those included with "include_if_exists" (a new feature added to PostgreSQL 9.2).
Versions:
Ubuntu 12.04.1
PostgreSQL 9.2.2-0ppa1~precise
postgresql-common 139~precise
To post a comment you must log in.
Here is a fix that's working for me:
- add "(_if_exists)?" to the regex.
- set $path = $2 (previously $path = $1)
Here is the result of the change, with line numbers in PgCommon.pm:
108 } elsif (/^\s*include( _if_exists) ?\s+'([ ^']+)'\ s*$/i) {
109 my ($k, $v, $path, %include_conf);
110 $path = $2;