forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit6bbd8b7
committed
Use AbsoluteConfigLocation() when building an included path in hba.c
The code building an absolute path to a file included, as prefixed by'@' in authentication files, for user and database lists uses the samelogic as for GUCs, except that it has no need to know about DataDir asthere is always a calling file to rely to build the base directory path.The refactoring done ina1a7bb8 makes this move straight-forward, andunifies the code used for GUCs and authentication files, and theintention is to rely also on that for the upcoming patch to be able toinclude full files from HBA or ident files.Note that this gets rid of an inconsistency introduced in370f909, thatcopied the logic coming from GUCs but applied it for files included inauthentication files, where the result buffer given tojoin_path_components() must have a size of MAXPGPATH. Based on adouble-check of the existing code, all the other callers ofjoin_path_components() already do that, except the code path changedhere.Discussion:https://postgr.es/m/Y2igk7q8OMpg+Yta@paquier.xyz1 parentf05a5e0 commit6bbd8b7
2 files changed
+4
-17
lines changedLines changed: 2 additions & 15 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
41 | 41 |
| |
42 | 42 |
| |
43 | 43 |
| |
| 44 | + | |
44 | 45 |
| |
45 | 46 |
| |
46 | 47 |
| |
| |||
466 | 467 |
| |
467 | 468 |
| |
468 | 469 |
| |
469 |
| - | |
470 |
| - | |
471 |
| - | |
472 |
| - | |
473 |
| - | |
474 |
| - | |
475 |
| - | |
476 |
| - | |
477 |
| - | |
478 |
| - | |
479 |
| - | |
480 |
| - | |
481 |
| - | |
482 |
| - | |
483 |
| - | |
| 470 | + | |
484 | 471 |
| |
485 | 472 |
| |
486 | 473 |
| |
|
Lines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
35 | 35 |
| |
36 | 36 |
| |
37 | 37 |
| |
38 |
| - | |
39 |
| - | |
40 | 38 |
| |
41 | 39 |
| |
42 | 40 |
| |
43 | 41 |
| |
| 42 | + | |
| 43 | + | |
44 | 44 |
| |
45 | 45 |
| |
46 | 46 |
| |
|
0 commit comments
Comments
(0)