commit
cbeded839d
@ -32,6 +32,7 @@ Checks: >
|
||||
-cppcoreguidelines-avoid-do-while,
|
||||
-cppcoreguidelines-avoid-magic-numbers,
|
||||
-cppcoreguidelines-avoid-non-const-global-variables,
|
||||
-cppcoreguidelines-macro-to-enum,
|
||||
-cppcoreguidelines-pro-type-vararg,
|
||||
-google-readability-braces-around-statements,
|
||||
-google-readability-todo,
|
||||
|
@ -13,7 +13,7 @@ class SdlButtonList
|
||||
|
||||
bool populate(SDL_Renderer* renderer, const std::vector<std::string>& labels,
|
||||
const std::vector<int>& ids, Sint32 total_width, Sint32 offsetY, Sint32 width,
|
||||
Sint32 heigth);
|
||||
Sint32 height);
|
||||
|
||||
bool update(SDL_Renderer* renderer);
|
||||
SdlButton* get_selected(const SDL_MouseButtonEvent& button);
|
||||
|
@ -82,7 +82,7 @@ class SDLConnectionDialog
|
||||
bool setTimer(Uint32 timeoutMS = 15000);
|
||||
void resetTimer();
|
||||
|
||||
static Uint32 timeout(Uint32 intervalMS, void* _this);
|
||||
static Uint32 timeout(Uint32 intervalMS, void* pvthis);
|
||||
|
||||
struct widget_cfg_t
|
||||
{
|
||||
|
@ -134,13 +134,13 @@ bool SdlInputWidget::remove_str(SDL_Renderer* renderer, size_t count)
|
||||
return update_input(renderer);
|
||||
}
|
||||
|
||||
bool SdlInputWidget::append_str(SDL_Renderer* renderer, const std::string& str)
|
||||
bool SdlInputWidget::append_str(SDL_Renderer* renderer, const std::string& text)
|
||||
{
|
||||
assert(renderer);
|
||||
if (readonly())
|
||||
return true;
|
||||
|
||||
_text.append(str);
|
||||
_text.append(text);
|
||||
if (!resize_input(_text.size()))
|
||||
return false;
|
||||
return update_input(renderer);
|
||||
|
@ -42,7 +42,7 @@ class SdlInputWidget
|
||||
bool update_label(SDL_Renderer* renderer);
|
||||
|
||||
bool set_mouseover(SDL_Renderer* renderer, bool mouseOver);
|
||||
bool set_highlight(SDL_Renderer* renderer, bool hightlight);
|
||||
bool set_highlight(SDL_Renderer* renderer, bool highlight);
|
||||
bool update_input(SDL_Renderer* renderer);
|
||||
bool resize_input(size_t size);
|
||||
|
||||
@ -56,7 +56,7 @@ class SdlInputWidget
|
||||
[[nodiscard]] bool readonly() const;
|
||||
|
||||
protected:
|
||||
bool update_input(SDL_Renderer* renderer, SDL_Color fgclor);
|
||||
bool update_input(SDL_Renderer* renderer, SDL_Color fgcolor);
|
||||
|
||||
private:
|
||||
SdlInputWidget(const SdlInputWidget& other) = delete;
|
||||
|
@ -332,6 +332,8 @@ class SdlEventUpdateTriggerGuard
|
||||
{
|
||||
_sdl->update_complete.set();
|
||||
}
|
||||
SdlEventUpdateTriggerGuard(const SdlEventUpdateTriggerGuard&) = delete;
|
||||
SdlEventUpdateTriggerGuard(SdlEventUpdateTriggerGuard&&) = delete;
|
||||
};
|
||||
|
||||
static bool sdl_draw_to_window_rect(SdlContext* sdl, SdlWindow& window, SDL_Surface* surface,
|
||||
|
@ -25,5 +25,5 @@
|
||||
#include "sdl_types.hpp"
|
||||
|
||||
int sdl_list_monitors(SdlContext* sdl);
|
||||
BOOL sdl_detect_monitors(SdlContext* sdl, UINT32* pWidth, UINT32* pHeight);
|
||||
BOOL sdl_detect_monitors(SdlContext* sdl, UINT32* pMaxWidth, UINT32* pMaxHeight);
|
||||
INT64 sdl_monitor_id_for_index(SdlContext* sdl, UINT32 index);
|
||||
|
@ -46,7 +46,7 @@ class SdlWindow
|
||||
void setBordered(bool bordered);
|
||||
void raise();
|
||||
void resizeable(bool use);
|
||||
void fullscreen(bool use);
|
||||
void fullscreen(bool enter);
|
||||
|
||||
bool fill(Uint8 r = 0x00, Uint8 g = 0x00, Uint8 b = 0x00, Uint8 a = 0xff);
|
||||
bool blit(SDL_Surface* surface, SDL_Rect src, SDL_Rect& dst);
|
||||
|
@ -13,7 +13,7 @@ class SdlButtonList
|
||||
|
||||
bool populate(SDL_Renderer* renderer, const std::vector<std::string>& labels,
|
||||
const std::vector<int>& ids, Sint32 total_width, Sint32 offsetY, Sint32 width,
|
||||
Sint32 heigth);
|
||||
Sint32 height);
|
||||
|
||||
bool update(SDL_Renderer* renderer);
|
||||
SdlButton* get_selected(const SDL_MouseButtonEvent& button);
|
||||
|
@ -135,13 +135,13 @@ bool SdlInputWidget::remove_str(SDL_Renderer* renderer, size_t count)
|
||||
return update_input(renderer);
|
||||
}
|
||||
|
||||
bool SdlInputWidget::append_str(SDL_Renderer* renderer, const std::string& str)
|
||||
bool SdlInputWidget::append_str(SDL_Renderer* renderer, const std::string& text)
|
||||
{
|
||||
assert(renderer);
|
||||
if (readonly())
|
||||
return true;
|
||||
|
||||
_text.append(str);
|
||||
_text.append(text);
|
||||
if (!resize_input(_text.size()))
|
||||
return false;
|
||||
return update_input(renderer);
|
||||
|
@ -42,7 +42,7 @@ class SdlInputWidget
|
||||
bool update_label(SDL_Renderer* renderer);
|
||||
|
||||
bool set_mouseover(SDL_Renderer* renderer, bool mouseOver);
|
||||
bool set_highlight(SDL_Renderer* renderer, bool hightlight);
|
||||
bool set_highlight(SDL_Renderer* renderer, bool highlight);
|
||||
bool update_input(SDL_Renderer* renderer);
|
||||
bool resize_input(size_t size);
|
||||
|
||||
@ -56,7 +56,7 @@ class SdlInputWidget
|
||||
[[nodiscard]] bool readonly() const;
|
||||
|
||||
protected:
|
||||
bool update_input(SDL_Renderer* renderer, SDL_Color fgclor);
|
||||
bool update_input(SDL_Renderer* renderer, SDL_Color fgcolor);
|
||||
|
||||
private:
|
||||
SdlInputWidget(const SdlInputWidget& other) = delete;
|
||||
|
@ -333,6 +333,8 @@ class SdlEventUpdateTriggerGuard
|
||||
{
|
||||
_sdl->update_complete.set();
|
||||
}
|
||||
SdlEventUpdateTriggerGuard(const SdlEventUpdateTriggerGuard&) = delete;
|
||||
SdlEventUpdateTriggerGuard(SdlEventUpdateTriggerGuard&&) = delete;
|
||||
};
|
||||
|
||||
static bool sdl_draw_to_window_rect(SdlContext* sdl, SdlWindow& window, SDL_Surface* surface,
|
||||
|
@ -25,5 +25,5 @@
|
||||
#include "sdl_types.hpp"
|
||||
|
||||
int sdl_list_monitors(SdlContext* sdl);
|
||||
BOOL sdl_detect_monitors(SdlContext* sdl, UINT32* pWidth, UINT32* pHeight);
|
||||
BOOL sdl_detect_monitors(SdlContext* sdl, UINT32* pMaxWidth, UINT32* ppMaxHeight);
|
||||
INT64 sdl_monitor_id_for_index(SdlContext* sdl, UINT32 index);
|
||||
|
@ -46,7 +46,7 @@ class SdlWindow
|
||||
void setBordered(bool bordered);
|
||||
void raise();
|
||||
void resizeable(bool use);
|
||||
void fullscreen(bool use);
|
||||
void fullscreen(bool enter);
|
||||
|
||||
bool fill(Uint8 r = 0x00, Uint8 g = 0x00, Uint8 b = 0x00, Uint8 a = 0xff);
|
||||
bool blit(SDL_Surface* surface, const SDL_Rect& src, SDL_Rect& dst);
|
||||
|
@ -25,7 +25,7 @@
|
||||
|
||||
#include <freerdp/client/cliprdr.h>
|
||||
|
||||
wfClipboard* wlf_clipboard_new(wlfContext* wlc);
|
||||
wfClipboard* wlf_clipboard_new(wlfContext* wfc);
|
||||
void wlf_clipboard_free(wfClipboard* clipboard);
|
||||
|
||||
BOOL wlf_cliprdr_init(wfClipboard* clipboard, CliprdrClientContext* cliprdr);
|
||||
|
@ -30,7 +30,7 @@ xfFloatbar* xf_floatbar_new(xfContext* xfc, Window window, const char* title, DW
|
||||
BOOL xf_floatbar_is_locked(xfFloatbar* floatbar);
|
||||
BOOL xf_floatbar_event_process(xfFloatbar* floatbar, const XEvent* event);
|
||||
BOOL xf_floatbar_check_event(xfFloatbar* floatbar, const XEvent* event);
|
||||
BOOL xf_floatbar_toggle_fullscreen(xfFloatbar* floatbar, bool visible);
|
||||
BOOL xf_floatbar_toggle_fullscreen(xfFloatbar* floatbar, bool fullscreen);
|
||||
BOOL xf_floatbar_hide_and_show(xfFloatbar* floatbar);
|
||||
BOOL xf_floatbar_set_root_y(xfFloatbar* floatbar, int y);
|
||||
|
||||
|
@ -40,9 +40,9 @@ static void write_log(wLog* log, DWORD level, const char* fname, const char* fkt
|
||||
va_end(ap);
|
||||
}
|
||||
|
||||
char* Safe_XGetAtomNameEx(wLog* log, Display* display, Atom atom, const char* atomvar)
|
||||
char* Safe_XGetAtomNameEx(wLog* log, Display* display, Atom atom, const char* varname)
|
||||
{
|
||||
WLog_Print(log, log_level, "XGetAtomName(%s, 0x%08" PRIx32 ")", atomvar, atom);
|
||||
WLog_Print(log, log_level, "XGetAtomName(%s, 0x%08" PRIx32 ")", varname, atom);
|
||||
if (atom == None)
|
||||
return strdup("Atom_None");
|
||||
return XGetAtomName(display, atom);
|
||||
|
@ -2303,7 +2303,7 @@ fail:
|
||||
return rc;
|
||||
}
|
||||
|
||||
CliprdrLocalStream* cliprdr_local_stream_new(CliprdrFileContext* context, UINT32 lockId,
|
||||
CliprdrLocalStream* cliprdr_local_stream_new(CliprdrFileContext* context, UINT32 streamID,
|
||||
const char* data, size_t size)
|
||||
{
|
||||
WINPR_ASSERT(context);
|
||||
@ -2315,7 +2315,7 @@ CliprdrLocalStream* cliprdr_local_stream_new(CliprdrFileContext* context, UINT32
|
||||
if (!cliprdr_local_stream_update(stream, data, size))
|
||||
goto fail;
|
||||
|
||||
stream->lockId = lockId;
|
||||
stream->lockId = streamID;
|
||||
return stream;
|
||||
|
||||
fail:
|
||||
|
@ -1357,19 +1357,16 @@ BOOL freerdp_client_populate_rdp_file_from_settings(rdpFile* file, const rdpSett
|
||||
|
||||
BOOL freerdp_client_write_rdp_file(const rdpFile* file, const char* name, BOOL unicode)
|
||||
{
|
||||
FILE* fp = NULL;
|
||||
size_t size = 0;
|
||||
char* buffer = NULL;
|
||||
int status = 0;
|
||||
WCHAR* unicodestr = NULL;
|
||||
|
||||
if (!file || !name)
|
||||
return FALSE;
|
||||
|
||||
size = freerdp_client_write_rdp_file_buffer(file, NULL, 0);
|
||||
const size_t size = freerdp_client_write_rdp_file_buffer(file, NULL, 0);
|
||||
if (size == 0)
|
||||
return FALSE;
|
||||
buffer = (char*)calloc((size_t)(size + 1), sizeof(char));
|
||||
char* buffer = calloc(size + 1ULL, sizeof(char));
|
||||
|
||||
if (freerdp_client_write_rdp_file_buffer(file, buffer, size + 1) != size)
|
||||
{
|
||||
@ -1378,7 +1375,7 @@ BOOL freerdp_client_write_rdp_file(const rdpFile* file, const char* name, BOOL u
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
fp = winpr_fopen(name, "w+b");
|
||||
FILE* fp = winpr_fopen(name, "w+b");
|
||||
|
||||
if (fp)
|
||||
{
|
||||
|
7
libfreerdp/cache/bitmap.c
vendored
7
libfreerdp/cache/bitmap.c
vendored
@ -40,7 +40,7 @@
|
||||
#define TAG FREERDP_TAG("cache.bitmap")
|
||||
|
||||
static rdpBitmap* bitmap_cache_get(rdpBitmapCache* bitmapCache, UINT32 id, UINT32 index);
|
||||
static BOOL bitmap_cache_put(rdpBitmapCache* bitmap_cache, UINT32 id, UINT32 index,
|
||||
static BOOL bitmap_cache_put(rdpBitmapCache* bitmapCache, UINT32 id, UINT32 index,
|
||||
rdpBitmap* bitmap);
|
||||
|
||||
static BOOL update_gdi_memblt(rdpContext* context, MEMBLT_ORDER* memblt)
|
||||
@ -326,7 +326,10 @@ static int bitmap_cache_save_persistent(rdpBitmapCache* bitmapCache)
|
||||
cacheEntry.key64 = bitmap->key64;
|
||||
cacheEntry.width = bitmap->width;
|
||||
cacheEntry.height = bitmap->height;
|
||||
cacheEntry.size = (UINT32)(bitmap->width * bitmap->height * 4);
|
||||
const UINT64 size = 4ULL * bitmap->width * bitmap->height;
|
||||
if (size > UINT32_MAX)
|
||||
continue;
|
||||
cacheEntry.size = (UINT32)size;
|
||||
cacheEntry.flags = 0;
|
||||
cacheEntry.data = bitmap->data;
|
||||
|
||||
|
10
libfreerdp/cache/glyph.c
vendored
10
libfreerdp/cache/glyph.c
vendored
@ -34,12 +34,12 @@
|
||||
|
||||
#define TAG FREERDP_TAG("cache.glyph")
|
||||
|
||||
static rdpGlyph* glyph_cache_get(rdpGlyphCache* glyph_cache, UINT32 id, UINT32 index);
|
||||
static BOOL glyph_cache_put(rdpGlyphCache* glyph_cache, UINT32 id, UINT32 index, rdpGlyph* entry);
|
||||
static rdpGlyph* glyph_cache_get(rdpGlyphCache* glyphCache, UINT32 id, UINT32 index);
|
||||
static BOOL glyph_cache_put(rdpGlyphCache* glyphCache, UINT32 id, UINT32 index, rdpGlyph* glyph);
|
||||
|
||||
static const void* glyph_cache_fragment_get(rdpGlyphCache* glyph, UINT32 index, UINT32* count);
|
||||
static BOOL glyph_cache_fragment_put(rdpGlyphCache* glyph, UINT32 index, UINT32 count,
|
||||
const void* entry);
|
||||
static const void* glyph_cache_fragment_get(rdpGlyphCache* glyphCache, UINT32 index, UINT32* size);
|
||||
static BOOL glyph_cache_fragment_put(rdpGlyphCache* glyphCache, UINT32 index, UINT32 size,
|
||||
const void* fragment);
|
||||
|
||||
static UINT32 update_glyph_offset(const BYTE* data, size_t length, UINT32 index, INT32* x, INT32* y,
|
||||
UINT32 ulCharInc, UINT32 flAccel)
|
||||
|
3
libfreerdp/cache/offscreen.c
vendored
3
libfreerdp/cache/offscreen.c
vendored
@ -44,8 +44,7 @@ struct rdp_offscreen_cache
|
||||
rdpContext* context;
|
||||
};
|
||||
|
||||
static void offscreen_cache_put(rdpOffscreenCache* offscreen_cache, UINT32 index,
|
||||
rdpBitmap* bitmap);
|
||||
static void offscreen_cache_put(rdpOffscreenCache* offscreenCache, UINT32 index, rdpBitmap* bitmap);
|
||||
static void offscreen_cache_delete(rdpOffscreenCache* offscreen, UINT32 index);
|
||||
|
||||
static BOOL
|
||||
|
@ -1356,11 +1356,6 @@ BOOL freerdp_assistance_populate_settings_from_assistance_file(rdpAssistanceFile
|
||||
|
||||
for (size_t x = 0; x < ports; x++)
|
||||
{
|
||||
union
|
||||
{
|
||||
UINT32 port;
|
||||
void* data;
|
||||
} cnv;
|
||||
cnv.data = ArrayList_GetItem(file->MachinePorts, x);
|
||||
if (!freerdp_settings_set_pointer_array(settings, FreeRDP_TargetNetPorts, x, &cnv.port))
|
||||
return FALSE;
|
||||
|
@ -2011,9 +2011,9 @@ BOOL gcc_read_client_cluster_data(wStream* s, rdpMcs* mcs)
|
||||
settings->RedirectSmartCards =
|
||||
(settings->ClusterInfoFlags & REDIRECTED_SMARTCARD) ? TRUE : FALSE;
|
||||
|
||||
if (blockLength != 8)
|
||||
if (blockLength > 8ULL)
|
||||
{
|
||||
if (Stream_GetRemainingLength(s) >= (size_t)(blockLength - 8))
|
||||
if (Stream_GetRemainingLength(s) >= (blockLength - 8ULL))
|
||||
{
|
||||
/* The old Microsoft Mac RDP client can send a pad here */
|
||||
Stream_Seek(s, (blockLength - 8));
|
||||
|
@ -155,7 +155,7 @@ struct rdp_mcs
|
||||
#define MCS_TYPE_CONNECT_RESPONSE 0x66
|
||||
|
||||
const char* mcs_domain_pdu_string(DomainMCSPDU pdu);
|
||||
BOOL mcs_server_apply_to_settings(const rdpMcs* msc, rdpSettings* settings);
|
||||
BOOL mcs_server_apply_to_settings(const rdpMcs* mcs, rdpSettings* settings);
|
||||
|
||||
FREERDP_LOCAL BOOL mcs_recv_connect_initial(rdpMcs* mcs, wStream* s);
|
||||
FREERDP_LOCAL BOOL mcs_recv_connect_response(rdpMcs* mcs, wStream* s);
|
||||
|
@ -204,30 +204,6 @@ static void scard_context_free(void* context)
|
||||
free(ctx);
|
||||
}
|
||||
|
||||
static BOOL char_compare(const void* a, const void* b)
|
||||
{
|
||||
const CHAR* wa = a;
|
||||
const CHAR* wb = b;
|
||||
|
||||
if (!a && !b)
|
||||
return TRUE;
|
||||
if (!a || !b)
|
||||
return FALSE;
|
||||
return strcmp(wa, wb) == 0;
|
||||
}
|
||||
|
||||
static BOOL wchar_compare(const void* a, const void* b)
|
||||
{
|
||||
const WCHAR* wa = a;
|
||||
const WCHAR* wb = b;
|
||||
|
||||
if (!a && !b)
|
||||
return TRUE;
|
||||
if (!a || !b)
|
||||
return FALSE;
|
||||
return _wcscmp(wa, wb) == 0;
|
||||
}
|
||||
|
||||
static SCardContext* scard_context_new(void)
|
||||
{
|
||||
SCardContext* ctx = calloc(1, sizeof(SCardContext));
|
||||
@ -247,7 +223,7 @@ static SCardContext* scard_context_new(void)
|
||||
ctx->cache = HashTable_New(FALSE);
|
||||
if (!ctx->cache)
|
||||
goto fail;
|
||||
else if (!HashTable_SetupForStringData(ctx->cache, FALSE))
|
||||
if (!HashTable_SetupForStringData(ctx->cache, FALSE))
|
||||
goto fail;
|
||||
else
|
||||
{
|
||||
@ -483,9 +459,9 @@ LONG WINAPI Emulate_SCardIsValidContext(SmartcardEmulationContext* smartcard, SC
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardListReaderGroupsA(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPSTR mszGroups,
|
||||
LPDWORD pcchGroups)
|
||||
LONG WINAPI Emulate_SCardListReaderGroupsA(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext,
|
||||
LPSTR mszGroups /* NOLINT(readability-non-const-parameter) */, LPDWORD pcchGroups)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -496,7 +472,8 @@ LONG WINAPI Emulate_SCardListReaderGroupsA(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(pcchGroups);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListReaderGroupsA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -505,9 +482,9 @@ LONG WINAPI Emulate_SCardListReaderGroupsA(SmartcardEmulationContext* smartcard,
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardListReaderGroupsW(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPWSTR mszGroups,
|
||||
LPDWORD pcchGroups)
|
||||
LONG WINAPI Emulate_SCardListReaderGroupsW(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext,
|
||||
LPWSTR mszGroups /* NOLINT(readability-non-const-parameter) */, LPDWORD pcchGroups)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -518,7 +495,8 @@ LONG WINAPI Emulate_SCardListReaderGroupsW(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(pcchGroups);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListReaderGroupsW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -609,7 +587,9 @@ LONG WINAPI Emulate_SCardListReadersW(SmartcardEmulationContext* smartcard, SCAR
|
||||
|
||||
LONG WINAPI Emulate_SCardListCardsA(SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext,
|
||||
LPCBYTE pbAtr, LPCGUID rgquidInterfaces,
|
||||
DWORD cguidInterfaceCount, CHAR* mszCards, LPDWORD pcchCards)
|
||||
DWORD cguidInterfaceCount,
|
||||
CHAR* mszCards /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchCards /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -623,7 +603,8 @@ LONG WINAPI Emulate_SCardListCardsA(SmartcardEmulationContext* smartcard, SCARDC
|
||||
WINPR_UNUSED(pcchCards);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListCardsA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -634,7 +615,9 @@ LONG WINAPI Emulate_SCardListCardsA(SmartcardEmulationContext* smartcard, SCARDC
|
||||
|
||||
LONG WINAPI Emulate_SCardListCardsW(SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext,
|
||||
LPCBYTE pbAtr, LPCGUID rgquidInterfaces,
|
||||
DWORD cguidInterfaceCount, WCHAR* mszCards, LPDWORD pcchCards)
|
||||
DWORD cguidInterfaceCount,
|
||||
WCHAR* mszCards /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchCards /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -648,7 +631,8 @@ LONG WINAPI Emulate_SCardListCardsW(SmartcardEmulationContext* smartcard, SCARDC
|
||||
WINPR_UNUSED(pcchCards);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListCardsW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -657,9 +641,9 @@ LONG WINAPI Emulate_SCardListCardsW(SmartcardEmulationContext* smartcard, SCARDC
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardListInterfacesA(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPCSTR szCard,
|
||||
LPGUID pguidInterfaces, LPDWORD pcguidInterfaces)
|
||||
LONG WINAPI Emulate_SCardListInterfacesA(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCSTR szCard,
|
||||
LPGUID pguidInterfaces, LPDWORD pcguidInterfaces /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -671,7 +655,8 @@ LONG WINAPI Emulate_SCardListInterfacesA(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(pcguidInterfaces);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListInterfacesA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -680,9 +665,9 @@ LONG WINAPI Emulate_SCardListInterfacesA(SmartcardEmulationContext* smartcard,
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardListInterfacesW(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPCWSTR szCard,
|
||||
LPGUID pguidInterfaces, LPDWORD pcguidInterfaces)
|
||||
LONG WINAPI Emulate_SCardListInterfacesW(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCWSTR szCard,
|
||||
LPGUID pguidInterfaces, LPDWORD pcguidInterfaces /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -694,7 +679,8 @@ LONG WINAPI Emulate_SCardListInterfacesW(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(pcguidInterfaces);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListInterfacesW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -715,7 +701,8 @@ LONG WINAPI Emulate_SCardGetProviderIdA(SmartcardEmulationContext* smartcard, SC
|
||||
WINPR_UNUSED(pguidProviderId);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetProviderIdA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -736,7 +723,8 @@ LONG WINAPI Emulate_SCardGetProviderIdW(SmartcardEmulationContext* smartcard, SC
|
||||
WINPR_UNUSED(pguidProviderId);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetProviderIdW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -745,10 +733,10 @@ LONG WINAPI Emulate_SCardGetProviderIdW(SmartcardEmulationContext* smartcard, SC
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardGetCardTypeProviderNameA(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPCSTR szCardName,
|
||||
DWORD dwProviderId, CHAR* szProvider,
|
||||
LPDWORD pcchProvider)
|
||||
LONG WINAPI Emulate_SCardGetCardTypeProviderNameA(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCSTR szCardName,
|
||||
DWORD dwProviderId, CHAR* szProvider /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchProvider /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -761,7 +749,8 @@ LONG WINAPI Emulate_SCardGetCardTypeProviderNameA(SmartcardEmulationContext* sma
|
||||
WINPR_UNUSED(pcchProvider);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetCardTypeProviderNameA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -770,10 +759,10 @@ LONG WINAPI Emulate_SCardGetCardTypeProviderNameA(SmartcardEmulationContext* sma
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardGetCardTypeProviderNameW(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPCWSTR szCardName,
|
||||
DWORD dwProviderId, WCHAR* szProvider,
|
||||
LPDWORD pcchProvider)
|
||||
LONG WINAPI Emulate_SCardGetCardTypeProviderNameW(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCWSTR szCardName,
|
||||
DWORD dwProviderId, WCHAR* szProvider /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchProvider /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -786,7 +775,8 @@ LONG WINAPI Emulate_SCardGetCardTypeProviderNameW(SmartcardEmulationContext* sma
|
||||
WINPR_UNUSED(pcchProvider);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetCardTypeProviderNameW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -806,7 +796,8 @@ LONG WINAPI Emulate_SCardIntroduceReaderGroupA(SmartcardEmulationContext* smartc
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardIntroduceReaderGroupA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -826,7 +817,8 @@ LONG WINAPI Emulate_SCardIntroduceReaderGroupW(SmartcardEmulationContext* smartc
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardIntroduceReaderGroupW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -846,7 +838,8 @@ LONG WINAPI Emulate_SCardForgetReaderGroupA(SmartcardEmulationContext* smartcard
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardForgetReaderGroupA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -866,7 +859,8 @@ LONG WINAPI Emulate_SCardForgetReaderGroupW(SmartcardEmulationContext* smartcard
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardForgetReaderGroupW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -890,7 +884,8 @@ LONG WINAPI Emulate_SCardIntroduceReaderA(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(szDeviceName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardIntroduceReaderA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -914,7 +909,8 @@ LONG WINAPI Emulate_SCardIntroduceReaderW(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(szDeviceName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardIntroduceReaderW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -935,7 +931,8 @@ LONG WINAPI Emulate_SCardForgetReaderA(SmartcardEmulationContext* smartcard, SCA
|
||||
(void*)hContext);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardForgetReaderA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -956,7 +953,8 @@ LONG WINAPI Emulate_SCardForgetReaderW(SmartcardEmulationContext* smartcard, SCA
|
||||
(void*)hContext);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardForgetReaderW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -980,7 +978,8 @@ LONG WINAPI Emulate_SCardAddReaderToGroupA(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardAddReaderToGroupA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1004,7 +1003,8 @@ LONG WINAPI Emulate_SCardAddReaderToGroupW(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardAddReaderToGroupW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1028,7 +1028,8 @@ LONG WINAPI Emulate_SCardRemoveReaderFromGroupA(SmartcardEmulationContext* smart
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardRemoveReaderFromGroupA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -1052,7 +1053,8 @@ LONG WINAPI Emulate_SCardRemoveReaderFromGroupW(SmartcardEmulationContext* smart
|
||||
WINPR_UNUSED(szGroupName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardRemoveReaderFromGroupW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -1081,7 +1083,8 @@ LONG WINAPI Emulate_SCardIntroduceCardTypeA(SmartcardEmulationContext* smartcard
|
||||
WINPR_UNUSED(cbAtrLen);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardIntroduceCardTypeA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -1110,7 +1113,8 @@ LONG WINAPI Emulate_SCardIntroduceCardTypeW(SmartcardEmulationContext* smartcard
|
||||
WINPR_UNUSED(cbAtrLen);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardIntroduceCardTypeW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -1133,7 +1137,8 @@ LONG WINAPI Emulate_SCardSetCardTypeProviderNameA(SmartcardEmulationContext* sma
|
||||
WINPR_UNUSED(szProvider);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardSetCardTypeProviderNameA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -1156,7 +1161,8 @@ LONG WINAPI Emulate_SCardSetCardTypeProviderNameW(SmartcardEmulationContext* sma
|
||||
WINPR_UNUSED(szProvider);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardSetCardTypeProviderNameW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -1176,7 +1182,8 @@ LONG WINAPI Emulate_SCardForgetCardTypeA(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(szCardName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardForgetCardTypeA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1196,7 +1203,8 @@ LONG WINAPI Emulate_SCardForgetCardTypeW(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(szCardName);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardForgetCardTypeW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1270,7 +1278,8 @@ LONG WINAPI Emulate_SCardLocateCardsA(SmartcardEmulationContext* smartcard, SCAR
|
||||
WINPR_UNUSED(cReaders);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardLocateCardsA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1293,7 +1302,8 @@ LONG WINAPI Emulate_SCardLocateCardsW(SmartcardEmulationContext* smartcard, SCAR
|
||||
WINPR_UNUSED(cReaders);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardLocateCardsW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1318,7 +1328,8 @@ LONG WINAPI Emulate_SCardLocateCardsByATRA(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(cReaders);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardLocateCardsByATRA } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -1343,7 +1354,8 @@ LONG WINAPI Emulate_SCardLocateCardsByATRW(SmartcardEmulationContext* smartcard,
|
||||
WINPR_UNUSED(cReaders);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardLocateCardsByATRW } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -2017,9 +2029,10 @@ LONG WINAPI Emulate_SCardGetTransmitCount(SmartcardEmulationContext* smartcard,
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardControl(SmartcardEmulationContext* smartcard, SCARDHANDLE hCard,
|
||||
DWORD dwControlCode, LPCVOID lpInBuffer, DWORD cbInBufferSize,
|
||||
LPVOID lpOutBuffer, DWORD cbOutBufferSize, LPDWORD lpBytesReturned)
|
||||
LONG WINAPI Emulate_SCardControl(
|
||||
SmartcardEmulationContext* smartcard, SCARDHANDLE hCard, DWORD dwControlCode,
|
||||
LPCVOID lpInBuffer, DWORD cbInBufferSize, LPVOID lpOutBuffer, DWORD cbOutBufferSize,
|
||||
LPDWORD lpBytesReturned /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = scard_handle_valid(smartcard, hCard);
|
||||
|
||||
@ -2046,7 +2059,9 @@ LONG WINAPI Emulate_SCardControl(SmartcardEmulationContext* smartcard, SCARDHAND
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardGetAttrib(SmartcardEmulationContext* smartcard, SCARDHANDLE hCard,
|
||||
DWORD dwAttrId, LPBYTE pbAttr, LPDWORD pcbAttrLen)
|
||||
DWORD dwAttrId,
|
||||
LPBYTE pbAttr /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcbAttrLen /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = scard_handle_valid(smartcard, hCard);
|
||||
|
||||
@ -2058,7 +2073,8 @@ LONG WINAPI Emulate_SCardGetAttrib(SmartcardEmulationContext* smartcard, SCARDHA
|
||||
WINPR_UNUSED(pcbAttrLen);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_F_INTERNAL_ERROR;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_F_INTERNAL_ERROR;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetAttrib } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -2080,7 +2096,8 @@ LONG WINAPI Emulate_SCardSetAttrib(SmartcardEmulationContext* smartcard, SCARDHA
|
||||
WINPR_UNUSED(cbAttrLen);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_F_INTERNAL_ERROR;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_F_INTERNAL_ERROR;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardSetAttrib } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status),
|
||||
@ -2506,10 +2523,10 @@ LONG WINAPI Emulate_SCardGetDeviceTypeIdW(SmartcardEmulationContext* smartcard,
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdA(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPCSTR szReaderName,
|
||||
LPSTR szDeviceInstanceId,
|
||||
LPDWORD pcchDeviceInstanceId)
|
||||
LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdA(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCSTR szReaderName,
|
||||
LPSTR szDeviceInstanceId /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchDeviceInstanceId /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -2523,7 +2540,8 @@ LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdA(SmartcardEmulationContext* s
|
||||
WINPR_UNUSED(pcchDeviceInstanceId);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetReaderDeviceInstanceIdA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -2532,10 +2550,10 @@ LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdA(SmartcardEmulationContext* s
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdW(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext, LPCWSTR szReaderName,
|
||||
LPWSTR szDeviceInstanceId,
|
||||
LPDWORD pcchDeviceInstanceId)
|
||||
LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdW(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCWSTR szReaderName,
|
||||
LPWSTR szDeviceInstanceId /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchDeviceInstanceId /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -2549,7 +2567,8 @@ LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdW(SmartcardEmulationContext* s
|
||||
WINPR_UNUSED(pcchDeviceInstanceId);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardGetReaderDeviceInstanceIdW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -2558,10 +2577,10 @@ LONG WINAPI Emulate_SCardGetReaderDeviceInstanceIdW(SmartcardEmulationContext* s
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdA(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext,
|
||||
LPCSTR szDeviceInstanceId,
|
||||
LPSTR mszReaders, LPDWORD pcchReaders)
|
||||
LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdA(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCSTR szDeviceInstanceId,
|
||||
LPSTR mszReaders /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchReaders /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -2573,7 +2592,8 @@ LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdA(SmartcardEmulationCont
|
||||
WINPR_UNUSED(pcchReaders);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListReadersWithDeviceInstanceIdA } status: %s (0x%08" PRIX32 ")",
|
||||
@ -2582,10 +2602,9 @@ LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdA(SmartcardEmulationCont
|
||||
return status;
|
||||
}
|
||||
|
||||
LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdW(SmartcardEmulationContext* smartcard,
|
||||
SCARDCONTEXT hContext,
|
||||
LPCWSTR szDeviceInstanceId,
|
||||
LPWSTR mszReaders, LPDWORD pcchReaders)
|
||||
LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdW(
|
||||
SmartcardEmulationContext* smartcard, SCARDCONTEXT hContext, LPCWSTR szDeviceInstanceId,
|
||||
LPWSTR mszReaders /* NOLINT(readability-non-const-parameter) */, LPDWORD pcchReaders)
|
||||
{
|
||||
LONG status = Emulate_SCardIsValidContext(smartcard, hContext);
|
||||
|
||||
@ -2597,7 +2616,8 @@ LONG WINAPI Emulate_SCardListReadersWithDeviceInstanceIdW(SmartcardEmulationCont
|
||||
WINPR_UNUSED(pcchReaders);
|
||||
|
||||
/* Not required, return not supported */
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardListReadersWithDeviceInstanceIdW } status: %s (0x%08" PRIX32 ")",
|
||||
@ -2617,7 +2637,8 @@ LONG WINAPI Emulate_SCardAudit(SmartcardEmulationContext* smartcard, SCARDCONTEX
|
||||
(void*)hContext);
|
||||
|
||||
// TODO: Implement
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
if (status == SCARD_S_SUCCESS)
|
||||
status = SCARD_E_UNSUPPORTED_FEATURE;
|
||||
|
||||
WLog_Print(smartcard->log, smartcard->log_default_level,
|
||||
"SCardAudit } status: %s (0x%08" PRIX32 ")", SCardGetErrorString(status), status);
|
||||
|
@ -91,9 +91,6 @@ static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R_general(const INT16* const WINP
|
||||
{
|
||||
for (UINT32 x = 0; x < roi->width; x++)
|
||||
{
|
||||
INT64 R = 0;
|
||||
INT64 G = 0;
|
||||
INT64 B = 0;
|
||||
const INT32 divisor = 16;
|
||||
const INT32 Y = (INT32)((UINT32)((*pY++) + 4096) << divisor);
|
||||
const INT32 Cb = (*pCb++);
|
||||
@ -102,9 +99,9 @@ static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R_general(const INT16* const WINP
|
||||
const INT64 CrG = Cr * (INT64)(0.714401f * (1 << divisor)) * 1LL;
|
||||
const INT64 CbG = Cb * (INT64)(0.343730f * (1 << divisor)) * 1LL;
|
||||
const INT64 CbB = Cb * (INT64)(1.769905f * (1 << divisor)) * 1LL;
|
||||
R = (INT64)((CrR + Y) >> (divisor + 5));
|
||||
G = (INT64)((Y - CbG - CrG) >> (divisor + 5));
|
||||
B = (INT64)((CbB + Y) >> (divisor + 5));
|
||||
const INT64 R = (CrR + Y) >> (divisor + 5);
|
||||
const INT64 G = (Y - CbG - CrG) >> (divisor + 5);
|
||||
const INT64 B = (CbB + Y) >> (divisor + 5);
|
||||
pRGB = writePixel(pRGB, formatSize, DstFormat, CLIP(R), CLIP(G), CLIP(B), 0);
|
||||
}
|
||||
|
||||
|
@ -434,7 +434,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->width = val;
|
||||
glyph->width = (INT32)val;
|
||||
}
|
||||
*q = '"';
|
||||
|
||||
@ -471,7 +471,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->offsetX = val;
|
||||
glyph->offsetX = (INT32)val;
|
||||
}
|
||||
{
|
||||
long val = strtol(tok[1], NULL, 0);
|
||||
@ -479,7 +479,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->offsetY = val;
|
||||
glyph->offsetY = (INT32)val;
|
||||
}
|
||||
*q = '"';
|
||||
p = q + 1;
|
||||
@ -525,7 +525,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->rectX = val;
|
||||
glyph->rectX = (INT32)val;
|
||||
}
|
||||
{
|
||||
long val = strtol(tok[1], NULL, 0);
|
||||
@ -533,7 +533,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->rectY = val;
|
||||
glyph->rectY = (INT32)val;
|
||||
}
|
||||
{
|
||||
long val = strtol(tok[2], NULL, 0);
|
||||
@ -541,7 +541,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->rectWidth = val;
|
||||
glyph->rectWidth = (INT32)val;
|
||||
}
|
||||
{
|
||||
long val = strtol(tok[3], NULL, 0);
|
||||
@ -549,7 +549,7 @@ static int rdtk_font_parse_descriptor_buffer(rdtkFont* font, uint8_t* buffer, si
|
||||
if ((errno != 0) || (val < INT32_MIN) || (val > INT32_MAX))
|
||||
return -1;
|
||||
|
||||
glyph->rectHeight = val;
|
||||
glyph->rectHeight = (INT32)val;
|
||||
}
|
||||
*q = '"';
|
||||
p = q + 1;
|
||||
|
@ -57,7 +57,7 @@ PfChannelResult channelTracker_update(ChannelStateTracker* tracker, const BYTE*
|
||||
UINT32 flags, size_t totalSize);
|
||||
|
||||
PfChannelResult channelTracker_flushCurrent(ChannelStateTracker* t, BOOL first, BOOL last,
|
||||
BOOL toFront);
|
||||
BOOL toBack);
|
||||
|
||||
BOOL pf_channel_setup_generic(pServerStaticChannelContext* channel);
|
||||
|
||||
|
@ -26,7 +26,7 @@ extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
BOOL shadow_client_accepted(freerdp_listener* instance, freerdp_peer* client);
|
||||
BOOL shadow_client_accepted(freerdp_listener* instance, freerdp_peer* peer);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -32,7 +32,7 @@
|
||||
#pragma clang diagnostic ignored "-Wreserved-id-macro"
|
||||
#endif
|
||||
|
||||
#define _GNU_SOURCE // NOLINT(bugprone-reserved-identifier)
|
||||
#define _GNU_SOURCE // NOLINT(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
|
||||
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
|
@ -23,7 +23,7 @@
|
||||
WINPR_PRAGMA_DIAG_PUSH
|
||||
WINPR_PRAGMA_DIAG_IGNORED_RESERVED_ID_MACRO
|
||||
|
||||
#define _FILE_OFFSET_BITS 64 // NOLINT(bugprone-reserved-identifier)
|
||||
#define _FILE_OFFSET_BITS 64 // NOLINT(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
|
||||
|
||||
WINPR_PRAGMA_DIAG_POP
|
||||
|
||||
|
@ -1170,8 +1170,9 @@ static LONG WINAPI PCSC_SCardListCardsW(SCARDCONTEXT hContext, LPCBYTE pbAtr,
|
||||
return SCARD_S_SUCCESS;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardListInterfacesA(SCARDCONTEXT hContext, LPCSTR szCard,
|
||||
LPGUID pguidInterfaces, LPDWORD pcguidInterfaces)
|
||||
static LONG WINAPI
|
||||
PCSC_SCardListInterfacesA(SCARDCONTEXT hContext, LPCSTR szCard, LPGUID pguidInterfaces,
|
||||
LPDWORD pcguidInterfaces /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szCard);
|
||||
@ -1180,8 +1181,9 @@ static LONG WINAPI PCSC_SCardListInterfacesA(SCARDCONTEXT hContext, LPCSTR szCar
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardListInterfacesW(SCARDCONTEXT hContext, LPCWSTR szCard,
|
||||
LPGUID pguidInterfaces, LPDWORD pcguidInterfaces)
|
||||
static LONG WINAPI
|
||||
PCSC_SCardListInterfacesW(SCARDCONTEXT hContext, LPCWSTR szCard, LPGUID pguidInterfaces,
|
||||
LPDWORD pcguidInterfaces /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szCard);
|
||||
@ -1208,9 +1210,10 @@ static LONG WINAPI PCSC_SCardGetProviderIdW(SCARDCONTEXT hContext, LPCWSTR szCar
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardGetCardTypeProviderNameA(SCARDCONTEXT hContext, LPCSTR szCardName,
|
||||
DWORD dwProviderId, CHAR* szProvider,
|
||||
LPDWORD pcchProvider)
|
||||
static LONG WINAPI PCSC_SCardGetCardTypeProviderNameA(
|
||||
SCARDCONTEXT hContext, LPCSTR szCardName, DWORD dwProviderId,
|
||||
CHAR* szProvider /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchProvider /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szCardName);
|
||||
@ -1220,9 +1223,10 @@ static LONG WINAPI PCSC_SCardGetCardTypeProviderNameA(SCARDCONTEXT hContext, LPC
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardGetCardTypeProviderNameW(SCARDCONTEXT hContext, LPCWSTR szCardName,
|
||||
DWORD dwProviderId, WCHAR* szProvider,
|
||||
LPDWORD pcchProvider)
|
||||
static LONG WINAPI PCSC_SCardGetCardTypeProviderNameW(
|
||||
SCARDCONTEXT hContext, LPCWSTR szCardName, DWORD dwProviderId,
|
||||
WCHAR* szProvider /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchProvider /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szCardName);
|
||||
@ -2957,8 +2961,10 @@ static LONG WINAPI PCSC_SCardWriteCacheW(SCARDCONTEXT hContext, UUID* CardIdenti
|
||||
return SCARD_S_SUCCESS;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardGetReaderIconA(SCARDCONTEXT hContext, LPCSTR szReaderName,
|
||||
LPBYTE pbIcon, LPDWORD pcbIcon)
|
||||
static LONG WINAPI
|
||||
PCSC_SCardGetReaderIconA(SCARDCONTEXT hContext, LPCSTR szReaderName,
|
||||
LPBYTE pbIcon /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcbIcon /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szReaderName);
|
||||
@ -2967,8 +2973,10 @@ static LONG WINAPI PCSC_SCardGetReaderIconA(SCARDCONTEXT hContext, LPCSTR szRead
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardGetReaderIconW(SCARDCONTEXT hContext, LPCWSTR szReaderName,
|
||||
LPBYTE pbIcon, LPDWORD pcbIcon)
|
||||
static LONG WINAPI
|
||||
PCSC_SCardGetReaderIconW(SCARDCONTEXT hContext, LPCWSTR szReaderName,
|
||||
LPBYTE pbIcon /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcbIcon /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szReaderName);
|
||||
@ -2998,9 +3006,10 @@ static LONG WINAPI PCSC_SCardGetDeviceTypeIdW(SCARDCONTEXT hContext, LPCWSTR szR
|
||||
return SCARD_S_SUCCESS;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardGetReaderDeviceInstanceIdA(SCARDCONTEXT hContext, LPCSTR szReaderName,
|
||||
LPSTR szDeviceInstanceId,
|
||||
LPDWORD pcchDeviceInstanceId)
|
||||
static LONG WINAPI PCSC_SCardGetReaderDeviceInstanceIdA(
|
||||
SCARDCONTEXT hContext, LPCSTR szReaderName,
|
||||
LPSTR szDeviceInstanceId /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchDeviceInstanceId /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szReaderName);
|
||||
@ -3009,9 +3018,10 @@ static LONG WINAPI PCSC_SCardGetReaderDeviceInstanceIdA(SCARDCONTEXT hContext, L
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardGetReaderDeviceInstanceIdW(SCARDCONTEXT hContext, LPCWSTR szReaderName,
|
||||
LPWSTR szDeviceInstanceId,
|
||||
LPDWORD pcchDeviceInstanceId)
|
||||
static LONG WINAPI PCSC_SCardGetReaderDeviceInstanceIdW(
|
||||
SCARDCONTEXT hContext, LPCWSTR szReaderName,
|
||||
LPWSTR szDeviceInstanceId /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchDeviceInstanceId /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szReaderName);
|
||||
@ -3020,9 +3030,10 @@ static LONG WINAPI PCSC_SCardGetReaderDeviceInstanceIdW(SCARDCONTEXT hContext, L
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardListReadersWithDeviceInstanceIdA(SCARDCONTEXT hContext,
|
||||
LPCSTR szDeviceInstanceId,
|
||||
LPSTR mszReaders, LPDWORD pcchReaders)
|
||||
static LONG WINAPI PCSC_SCardListReadersWithDeviceInstanceIdA(
|
||||
SCARDCONTEXT hContext, LPCSTR szDeviceInstanceId,
|
||||
LPSTR mszReaders /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchReaders /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szDeviceInstanceId);
|
||||
@ -3031,10 +3042,10 @@ static LONG WINAPI PCSC_SCardListReadersWithDeviceInstanceIdA(SCARDCONTEXT hCont
|
||||
return SCARD_E_UNSUPPORTED_FEATURE;
|
||||
}
|
||||
|
||||
static LONG WINAPI PCSC_SCardListReadersWithDeviceInstanceIdW(SCARDCONTEXT hContext,
|
||||
LPCWSTR szDeviceInstanceId,
|
||||
LPWSTR mszReaders,
|
||||
LPDWORD pcchReaders)
|
||||
static LONG WINAPI PCSC_SCardListReadersWithDeviceInstanceIdW(
|
||||
SCARDCONTEXT hContext, LPCWSTR szDeviceInstanceId,
|
||||
LPWSTR mszReaders /* NOLINT(readability-non-const-parameter) */,
|
||||
LPDWORD pcchReaders /* NOLINT(readability-non-const-parameter) */)
|
||||
{
|
||||
WINPR_UNUSED(hContext);
|
||||
WINPR_UNUSED(szDeviceInstanceId);
|
||||
|
@ -23,7 +23,7 @@
|
||||
WINPR_PRAGMA_DIAG_PUSH
|
||||
WINPR_PRAGMA_DIAG_IGNORED_RESERVED_ID_MACRO
|
||||
|
||||
#define _NO_KSECDD_IMPORT_ 1 // NOLINT(bugprone-reserved-identifier)
|
||||
#define _NO_KSECDD_IMPORT_ 1 // NOLINT(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
|
||||
|
||||
WINPR_PRAGMA_DIAG_POP
|
||||
|
||||
|
@ -40,7 +40,7 @@ WINPR_PRAGMA_DIAG_IGNORED_RESERVED_ID_MACRO
|
||||
|
||||
#ifdef WINPR_HAVE_UNISTD_H
|
||||
#ifndef _XOPEN_SOURCE
|
||||
#define _XOPEN_SOURCE 500 // NOLINT(bugprone-reserved-identifier)
|
||||
#define _XOPEN_SOURCE 500 // NOLINT(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
|
||||
#endif
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
@ -184,10 +184,11 @@ out:
|
||||
return ret;
|
||||
}
|
||||
|
||||
int apc_executeCompletions(WINPR_THREAD* thread, WINPR_POLL_SET* set, size_t idx)
|
||||
int apc_executeCompletions(WINPR_THREAD* thread, WINPR_POLL_SET* set, size_t startIndex)
|
||||
{
|
||||
APC_QUEUE* apc = NULL;
|
||||
WINPR_APC_ITEM* nextItem = NULL;
|
||||
size_t idx = startIndex;
|
||||
int ret = 0;
|
||||
|
||||
WINPR_ASSERT(thread);
|
||||
|
@ -15,7 +15,7 @@
|
||||
* http://www.codingunit.com/printf-format-specifiers-format-conversions-and-formatted-output
|
||||
*/
|
||||
|
||||
#define _printf printf // NOLINT(bugprone-reserved-identifier)
|
||||
#define _printf printf // NOLINT(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
|
||||
|
||||
static BOOL test_bin_tohex_string(void)
|
||||
{
|
||||
|
@ -19,7 +19,7 @@
|
||||
*/
|
||||
|
||||
#ifndef _GNU_SOURCE
|
||||
#define _GNU_SOURCE // NOLINT(bugprone-reserved-identifier)
|
||||
#define _GNU_SOURCE // NOLINT(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
|
||||
#endif
|
||||
|
||||
#include <assert.h>
|
||||
|
Loading…
Reference in New Issue
Block a user