mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-15 00:44:19 +09:00
[build] use define WINPR_FALLTHROUGH
with c17 compatible compilers annotate with [[fallthrough]]
This commit is contained in:
@@ -288,7 +288,9 @@ static void LIBUSB_CALL func_iso_callback(struct libusb_transfer* transfer)
|
||||
/* fallthrough */
|
||||
|
||||
case LIBUSB_TRANSFER_CANCELLED:
|
||||
WINPR_FALLTHROUGH
|
||||
case LIBUSB_TRANSFER_TIMED_OUT:
|
||||
WINPR_FALLTHROUGH
|
||||
case LIBUSB_TRANSFER_ERROR:
|
||||
{
|
||||
const UINT32 InterfaceId =
|
||||
|
||||
@@ -855,12 +855,16 @@ static int xf_input_handle_event_remote(xfContext* xfc, const XEvent* event)
|
||||
{
|
||||
case XI_TouchBegin:
|
||||
xf_input_pens_unhover(xfc);
|
||||
WINPR_FALLTHROUGH
|
||||
case XI_TouchUpdate:
|
||||
WINPR_FALLTHROUGH
|
||||
case XI_TouchEnd:
|
||||
xf_input_touch_remote(xfc, cookie.cc->data, cookie.cc->evtype);
|
||||
break;
|
||||
case XI_ButtonPress:
|
||||
WINPR_FALLTHROUGH
|
||||
case XI_Motion:
|
||||
WINPR_FALLTHROUGH
|
||||
case XI_ButtonRelease:
|
||||
{
|
||||
WLog_DBG(TAG, "checking for pen");
|
||||
@@ -873,6 +877,7 @@ static int xf_input_handle_event_remote(xfContext* xfc, const XEvent* event)
|
||||
break;
|
||||
}
|
||||
}
|
||||
WINPR_FALLTHROUGH
|
||||
default:
|
||||
xf_input_pens_unhover(xfc);
|
||||
xf_input_event(xfc, event, cookie.cc->data, cookie.cc->evtype);
|
||||
|
||||
@@ -707,6 +707,7 @@ void credssp_auth_free(rdpCredsspAuth* auth)
|
||||
WINPR_ASSERT(auth->table->DeleteSecurityContext);
|
||||
auth->table->DeleteSecurityContext(&auth->context);
|
||||
/* FALLTHROUGH */
|
||||
WINPR_FALLTHROUGH
|
||||
case AUTH_STATE_CREDS:
|
||||
WINPR_ASSERT(auth->table->FreeCredentialsHandle);
|
||||
auth->table->FreeCredentialsHandle(&auth->credentials);
|
||||
|
||||
@@ -287,6 +287,7 @@ static int rpc_client_recv_pdu(rdpRpc* rpc, RPC_PDU* pdu)
|
||||
return -1;
|
||||
}
|
||||
/* FALLTHROUGH */
|
||||
WINPR_FALLTHROUGH
|
||||
case RPC_BIND_STATE_COMPLETE:
|
||||
rpc_client_transition_to_state(rpc, RPC_CLIENT_STATE_CONTEXT_NEGOTIATED);
|
||||
|
||||
|
||||
@@ -20,6 +20,12 @@
|
||||
#ifndef WINPR_WTYPES_H
|
||||
#define WINPR_WTYPES_H
|
||||
|
||||
#if defined(__STDC__) && defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 201710L)
|
||||
#define WINPR_FALLTHROUGH [[fallthrough]]
|
||||
#else
|
||||
#define WINPR_FALLTHROUGH
|
||||
#endif
|
||||
|
||||
/* Set by CMake during configuration */
|
||||
#cmakedefine WINPR_HAVE_STDINT_H
|
||||
#cmakedefine WINPR_HAVE_STDBOOL_H
|
||||
|
||||
@@ -207,6 +207,8 @@ static CK_RV object_load_attributes(NCryptP11ProviderHandle* provider, CK_SESSIO
|
||||
if (!attributes_have_unallocated_buffers(attributes, count))
|
||||
return rv;
|
||||
/* fallthrough */
|
||||
WINPR_FALLTHROUGH
|
||||
|
||||
case CKR_ATTRIBUTE_SENSITIVE:
|
||||
case CKR_ATTRIBUTE_TYPE_INVALID:
|
||||
case CKR_BUFFER_TOO_SMALL:
|
||||
|
||||
@@ -818,6 +818,7 @@ static SECURITY_STATUS SEC_ENTRY kerberos_InitializeSecurityContextA(
|
||||
goto bad_token;
|
||||
|
||||
/* Continue to AP-REQ */
|
||||
WINPR_FALLTHROUGH
|
||||
|
||||
case KERBEROS_STATE_AP_REQ:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user