diff --git a/.cirrus.yml b/.cirrus.yml index 61f094c2b..0039f8c07 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -141,7 +141,7 @@ rocky_task: LC_ALL: C CIRRUS_CLONE_DEPTH: 1 USE_CONFIG: yes - CFLAGS: -std=gnu90 -Wformat -Wformat=2 + CFLAGS: -g -O3 -std=gnu90 -Wformat -Wformat=2 -Wextra -Wno-sign-compare -Wno-unused-parameter -Wno-missing-field-initializers -Wno-empty-body # NB: we could consider building a docker image with these # preinstalled and specifying that instead, to speed up testing. diff --git a/hts.c b/hts.c index 42be3f21f..a4ae32a69 100644 --- a/hts.c +++ b/hts.c @@ -1322,7 +1322,7 @@ int hts_parse_opt_list(htsFormat *fmt, const char *str) { * -1 on failure. */ int hts_parse_format(htsFormat *format, const char *str) { - char fmt[8]; + char fmt[9]; const char *cp = scan_keyword(str, ',', fmt, sizeof fmt); format->version.minor = 0; // unknown diff --git a/test/test-bcf-sr.c b/test/test-bcf-sr.c index b4943b5ef..e24954685 100644 --- a/test/test-bcf-sr.c +++ b/test/test-bcf-sr.c @@ -179,6 +179,7 @@ int main(int argc, char *argv[]) break; case 'h': usage(EXIT_SUCCESS); + // fall-through default: usage(EXIT_FAILURE); } }