diff --git a/.github/workflows/alt-architectures.yml b/.github/workflows/alt-architectures.yml index ecb829ca2..a5770f05b 100644 --- a/.github/workflows/alt-architectures.yml +++ b/.github/workflows/alt-architectures.yml @@ -13,8 +13,6 @@ jobs: fail-fast: false matrix: include: - - arch: armv6 - distro: bookworm - arch: armv7 distro: bookworm - arch: aarch64 diff --git a/channels/rdpdr/server/rdpdr_main.c b/channels/rdpdr/server/rdpdr_main.c index 353b1663c..9b8e8b208 100644 --- a/channels/rdpdr/server/rdpdr_main.c +++ b/channels/rdpdr/server/rdpdr_main.c @@ -124,10 +124,27 @@ fail: return NULL; } +static void* rdpdr_device_key_clone(const void* pvval) +{ + const UINT32* val = pvval; + if (!val) + return NULL; + + UINT32* ptr = calloc(1, sizeof(UINT32)); + if (!ptr) + return NULL; + *ptr = *val; + return ptr; +} + +static void rdpdr_device_key_free(void* obj) +{ + free(obj); +} + static RdpdrDevice* rdpdr_get_device_by_id(RdpdrServerPrivate* priv, UINT32 DeviceId) { WINPR_ASSERT(priv); - return HashTable_GetItemValue(priv->devicelist, &DeviceId); } @@ -3557,6 +3574,8 @@ static RdpdrServerPrivate* rdpdr_server_private_new(void) obj = HashTable_KeyObject(priv->devicelist); obj->fnObjectEquals = rdpdr_device_equal; + obj->fnObjectFree = rdpdr_device_key_free; + obj->fnObjectNew = rdpdr_device_key_clone; return priv; fail: