pgsql: Fix unportable disregard of alignment requirements in RADIUScod
В списке pgsql-committers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | pgsql: Fix unportable disregard of alignment requirements in RADIUScod |
| Дата | |
| Msg-id | E1csFpO-0003rB-E5@gemulon.postgresql.org обсуждение исходный текст |
| Список | pgsql-committers |
Fix unportable disregard of alignment requirements in RADIUS code. The compiler is entitled to store a char[] local variable with no particular alignment requirement. Our RADIUS code cavalierly took such a local variable and cast its address to a struct type that does have alignment requirements. On an alignment-picky machine this would lead to bus errors. To fix, declare the local variable honestly, and then cast its address to char * for use in the I/O calls. Given the lack of field complaints, there must be very few if any people affected; but nonetheless this is a clear portability issue, so back-patch to all supported branches. Noted while looking at a Coverity complaint in the same code. Branch ------ REL9_2_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/5fe937f38b493f7c94c4ef8b0940e034afbd78a6 Modified Files -------------- src/backend/libpq/auth.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-)
В списке pgsql-committers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера