diff options
-rw-r--r-- | meson.build | 4 | ||||
-rw-r--r-- | src/implementation.c | 2 | ||||
-rw-r--r-- | src/win.c | 4 |
3 files changed, 4 insertions, 6 deletions
diff --git a/meson.build b/meson.build index c135329..b3c88e6 100644 --- a/meson.build +++ b/meson.build @@ -77,16 +77,14 @@ if get_option('strict') endif elif cc.get_id() == 'msvc' c_warnings += [ - '/wd4028', # formal parameter different from declaration '/wd4061', # enumerator in switch is not explicitly handled '/wd4191', # unsafe conversion from type to type '/wd4514', # unreferenced inline function has been removed '/wd4706', # assignment within conditional expression '/wd4710', # function not inlined '/wd4711', # function selected for automatic inline expansion - '/wd4800', # implicit conversion from int to bool '/wd4820', # padding added after construct - '/wd4996', # function or variable may be unsafe + '/wd4996', # POSIX name for this item is deprecated '/wd5045', # will insert Spectre mitigation for memory load ] endif diff --git a/src/implementation.c b/src/implementation.c index afc16ab..e7835f6 100644 --- a/src/implementation.c +++ b/src/implementation.c @@ -375,7 +375,7 @@ puglDecodeUTF8(const uint8_t* buf) static inline bool puglMustConfigure(PuglView* view, const PuglConfigureEvent* configure) { - return memcmp(configure, &view->lastConfigure, sizeof(PuglConfigureEvent)); + return !!memcmp(configure, &view->lastConfigure, sizeof(PuglConfigureEvent)); } PuglStatus @@ -83,13 +83,13 @@ puglRegisterWindowClass(const char* name) wc.hbrBackground = (HBRUSH)GetStockObject(BLACK_BRUSH); wc.lpszClassName = name; - return RegisterClassEx(&wc); + return !!RegisterClassEx(&wc); } static unsigned puglWinGetWindowFlags(const PuglView* const view) { - const bool resizable = view->hints[PUGL_RESIZABLE]; + const bool resizable = !!view->hints[PUGL_RESIZABLE]; const unsigned sizeFlags = resizable ? (WS_SIZEBOX | WS_MAXIMIZEBOX) : 0u; return (WS_CLIPCHILDREN | WS_CLIPSIBLINGS | |