From fbd3c46d3215e5c28430982452fd49a93507cfc1 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 28 Jul 2005 21:15:53 +0000 Subject: [PATCH] don't log error if connection has been already terminated in HangUp() (patch 1243184) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34957 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/msw/dialup.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/msw/dialup.cpp b/src/msw/dialup.cpp index b4bb8d55ea..0114b7759e 100644 --- a/src/msw/dialup.cpp +++ b/src/msw/dialup.cpp @@ -947,8 +947,10 @@ bool wxDialUpManagerMSW::HangUp() return false; } - DWORD dwRet = ms_pfnRasHangUp(hRasConn); - if ( dwRet != 0 ) + // note that it's not an error if the connection had been already + // terminated + const DWORD dwRet = ms_pfnRasHangUp(hRasConn); + if ( dwRet != 0 && dwRet != ERROR_NO_CONNECTION ) { wxLogError(_("Failed to terminate the dialup connection: %s"), GetErrorString(dwRet).c_str()); -- 2.47.2