diff options
author | Harald Welte <laforge@osmocom.org> | 2022-11-06 10:53:34 +0100 |
---|---|---|
committer | Harald Welte <laforge@osmocom.org> | 2022-11-06 10:57:52 +0100 |
commit | be912e7c1d8234847a0c21974d2068223a60dd7e (patch) | |
tree | 7a8ae69d10666e200efcd1dbd2aa507483001133 /include | |
parent | de4e8daf7debb508ed4af7d4e5e51a7438f7bb96 (diff) |
Disable -Wstrict-prototypes for logging_vty_add_cmds()
Since March 15th 2017, libosmocore API logging_vty_add_cmds() had its
parameter removed (c65c5b4ea075ef6cef11fff9442ae0b15c1d6af7). However,
its declaration in C file didn't contain "(void)", which meant the
number of parameters is undefined and thus compiler doesn't complain.
However, in recent Change-Id I84fd99442d0cc400fa562fa33623c142649230e2
we changed the declaration to '(void)' to allow building with
-Wstrict-prototypes. This caused downstream build-failures of osmo-mgw (1.4.0)
and osmo-e1-recorder (master).
So let's make one very small-scoped exception here.
Change-Id: Iadb54848b67db937b640dc2102dddb6e708a6a9f
Diffstat (limited to 'include')
-rw-r--r-- | include/osmocom/vty/logging.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/osmocom/vty/logging.h b/include/osmocom/vty/logging.h index 0ea64321..9be96e56 100644 --- a/include/osmocom/vty/logging.h +++ b/include/osmocom/vty/logging.h @@ -6,7 +6,12 @@ #define FILTER_STR "Filter log messages\n" struct log_info; -void logging_vty_add_cmds(void); +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wstrict-prototypes" +/* note this undefined argument declaration is intentional. There used + * to be an argument until 2017 which we no longer need .*/ +void logging_vty_add_cmds(); +#pragma GCC diagnostic pop void logging_vty_add_deprecated_subsys(void *ctx, const char *name); struct vty; struct log_target *osmo_log_vty2tgt(struct vty *vty); |