diff options
author | Ivan Maidanski <ivmai@mail.ru> | 2021-06-13 10:38:57 +0300 |
---|---|---|
committer | Ivan Maidanski <ivmai@mail.ru> | 2021-06-13 10:38:57 +0300 |
commit | 5077b8daac5c96906a496be5565e96c229733e80 (patch) | |
tree | 75aa507ef3073b11d837039ae35364e1403fe98a /extra | |
parent | 676e2779d5035dd8eabfc68150f8e73185d6a3ec (diff) | |
download | bdwgc-5077b8daac5c96906a496be5565e96c229733e80.tar.gz |
Eliminate 'Consecutive return is unnecessary' cppcheck style warning
* extra/MacOS.c (GC_MacGetDataStart): Skip return if CPPCHECK; add
comment.
* extra/MacOS.c [far_data] (GC_MacGetDataEnd): Likewise.
Diffstat (limited to 'extra')
-rw-r--r-- | extra/MacOS.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/extra/MacOS.c b/extra/MacOS.c index 86557a90..082ee6ed 100644 --- a/extra/MacOS.c +++ b/extra/MacOS.c @@ -45,7 +45,9 @@ void* GC_MacGetDataStart(void) } fprintf(stderr, "Couldn't load the jump table."); exit(-1); - return 0; +# if !defined(CPPCHECK) + return 0; /* to avoid compiler complain about missing return */ +# endif } #ifdef USE_TEMPORARY_MEMORY @@ -159,7 +161,9 @@ void GC_MacFreeTemporaryMemory(void) } fprintf(stderr, "Couldn't load the jump table."); exit(-1); +# if !defined(CPPCHECK) return 0; +# endif } #endif /* __option(far_data) */ |