From 95c42353fb9e5fd34ca7d1887dde62e0a8ca2158 Mon Sep 17 00:00:00 2001 From: Pietro Gagliardi Date: Mon, 25 Aug 2014 01:44:14 -0400 Subject: [PATCH] Added error return checks to MessageBeep(); --- redo/basicctrls_windows.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/redo/basicctrls_windows.c b/redo/basicctrls_windows.c index c82c5d6..4c5a129 100644 --- a/redo/basicctrls_windows.c +++ b/redo/basicctrls_windows.c @@ -116,7 +116,8 @@ void textfieldSetAndShowInvalidBalloonTip(HWND hwnd, WCHAR *text) ti.ttiIcon = TTI_ERROR; if (SendMessageW(hwnd, EM_SHOWBALLOONTIP, 0, (LPARAM) (&ti)) == FALSE) xpanic("error showing TextField.Invalid() balloon tip", GetLastError()); - MessageBeep(0xFFFFFFFF); // TODO can this return an error? + if (MessageBeep(0xFFFFFFFF) == 0) + xpanic("error beeping in response to TextField.Invalid()", GetLastError()); } void textfieldHideInvalidBalloonTip(HWND hwnd)