Commit 0bc726d
committed
Make GetConfigOption/GetConfigOptionResetString return "" for NULL.
As per the preceding commit, GUC APIs generally expose NULL-valued
string variables as empty strings. Extend that policy to
GetConfigOption() and GetConfigOptionResetString(), eliminating
a crash hazard for unwary callers, as well as a fundamental
ambiguity in GetConfigOption()'s API.
No back-patch, since this is an API change and conceivably somebody
somewhere is depending on this corner case.
Xing Guo, Aleksander Alekseev, Tom Lane
Discussion: https://postgr.es/m/CACpMh+AyDx5YUpPaAgzVwC1d8zfOL4JoD-uyFDnNSa1z0EsDQQ@mail.gmail.com1 parent 7704a1a commit 0bc726d
1 file changed
+5
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4215 | 4215 | | |
4216 | 4216 | | |
4217 | 4217 | | |
4218 | | - | |
4219 | | - | |
| 4218 | + | |
4220 | 4219 | | |
4221 | 4220 | | |
4222 | 4221 | | |
| |||
4259 | 4258 | | |
4260 | 4259 | | |
4261 | 4260 | | |
4262 | | - | |
| 4261 | + | |
| 4262 | + | |
4263 | 4263 | | |
4264 | 4264 | | |
4265 | 4265 | | |
| |||
4306 | 4306 | | |
4307 | 4307 | | |
4308 | 4308 | | |
4309 | | - | |
| 4309 | + | |
| 4310 | + | |
4310 | 4311 | | |
4311 | 4312 | | |
4312 | 4313 | | |
| |||
0 commit comments