Bug 1359915 - Enable compile-time warnings for security-sensitive patterns. r=froydnj

This commit is contained in:
Nomis101 2017-06-01 00:25:03 +02:00
Родитель 984edc2be4
Коммит a6af209681
1 изменённых файлов: 5 добавлений и 0 удалений

Просмотреть файл

@ -112,6 +112,11 @@ check_and_add_gcc_warning('-Wno-format',
# We hit this all over the place with the gtest INSTANTIATE_TEST_CASE_P macro
check_and_add_gcc_warning('-Wno-gnu-zero-variadic-macro-arguments')
# Add compile-time warnings for unprotected functions and format functions
# that represent possible security problems
check_and_add_gcc_warning('-Wformat-security')
check_and_add_gcc_warning('-Wformat-overflow=2')
# Please keep these last in this file
add_old_configure_assignment('_WARNINGS_CFLAGS', warnings_cflags)
add_old_configure_assignment('_WARNINGS_CXXFLAGS', warnings_cxxflags)