1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
|
Description: Fix some compilation errors.
Bug: https://github.com/statgen/libStatGen/issues/15
https://github.com/statgen/libStatGen/issues/17
Origin: https://github.com/statgen/libStatGen/commit/2f1876e
https://github.com/statgen/libStatGen/commit/9db9c23
https://github.com/statgen/libStatGen/commit/5500464
https://github.com/statgen/libStatGen/commit/198a43e
--- a/general/Parameters.cpp
+++ b/general/Parameters.cpp
@@ -553,7 +553,7 @@
int line_len = 0;
bool legacy_parameters = false;
- bool legacy_count = 0;
+ int legacy_count = 0;
for (LongParameterList * ptr = list + 1; ptr->description != NULL; ptr++)
if (ptr->type == LP_LEGACY_PARAMETERS)
--- a/general/Makefile
+++ b/general/Makefile
@@ -8,7 +8,10 @@
# an error, but allow unused results and variables for the
# time being.
#
- USER_WARNINGS ?= -Werror $(shell if [ X$(CCVERSION) \> X4.2.0 ] ; then echo " -Wno-strict-overflow" ; fi)
+ # Disable format-truncation check because StringBasics specifically tests
+ # to make sure snprintf truncates as expected.
+ USER_WARNINGS ?= -Werror -Wno-format-truncation $(shell if [ X$(CCVERSION) \> X4.2.0 ] ; then echo " -Wno-strict-overflow" ; fi)
+# USER_WARNINGS ?= -Werror $(shell if [ X$(CCVERSION) \> X4.2.0 ] ; then echo " -Wno-strict-overflow" ; fi)
#-Wno-strict-overflow
# -Wno-unused-variable $(shell if [ X$(CCVERSION) \> X4.2.0 ] ; then echo " -Wno-unused-result" ; fi)
endif
|