commit 202d7a6582632e09587e4e91ef1603f647ecf338
parent 0201a789c24696cc9eab72aa984095d4b0d1f7cb
Author: Vincent Forest <vincent.forest@meso-star.com>
Date: Wed, 13 Oct 2021 16:58:12 +0200
Merge branch 'release_0.0.3'
Diffstat:
4 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
@@ -21,6 +21,10 @@ CMake.
## Release notes
+### Version 0.0.3
+
+Fix compilation warnings detected by gcc 11
+
### Version 0.0.2
Sets the CMake minimum version to 3.1: since CMake 3.20, version 2.8 has become
diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt
@@ -37,7 +37,7 @@ include_directories(${RSys_INCLUDE_DIR})
################################################################################
set(VERSION_MAJOR 0)
set(VERSION_MINOR 0)
-set(VERSION_PATCH 2)
+set(VERSION_PATCH 3)
set(VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH})
set(SCMAP_FILES_SRC scmap.c scmap_palettes.c)
diff --git a/src/scmap_palettes.c b/src/scmap_palettes.c
@@ -1797,7 +1797,7 @@ get_color(const size_t icolor, double color[3], void* context)
#define DEFINE_PALETTE(Palette) \
const struct scmap_palette scmap_palette_##Palette = { \
- get_color, sizeof(Palette)/sizeof(double[3]), (void*)Palette \
+ get_color, sizeof(Palette)/(sizeof(double)*3), (void*)Palette \
}
DEFINE_PALETTE(accent);
DEFINE_PALETTE(blues);
diff --git a/src/test_scmap_fetch_color.c b/src/test_scmap_fetch_color.c
@@ -29,7 +29,7 @@ static const double colors[] = {
0.4, 0.4, 0.4,
0.5, 0.5, 0.5
};
-static const size_t ncolors = sizeof(colors)/sizeof(double[3]);
+static const size_t ncolors = sizeof(colors)/(sizeof(double)*3);
static void
get_color(const size_t i, double col[3], void* context)