aboutsummaryrefslogtreecommitdiffstats
path: root/api/adapter.c
diff options
context:
space:
mode:
Diffstat (limited to 'api/adapter.c')
-rw-r--r--api/adapter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/api/adapter.c b/api/adapter.c
index ab79f0c..0dd8c42 100644
--- a/api/adapter.c
+++ b/api/adapter.c
@@ -523,7 +523,7 @@ DeviceCreateCallback(
SW_DEVICE_CREATE_CTX *Ctx = Context;
Ctx->CreateResult = CreateResult;
if (DeviceInstanceId)
- wcsncpy_s(Ctx->DeviceInstanceId, MAX_INSTANCE_ID, DeviceInstanceId, _TRUNCATE);
+ wcsncpy_s(Ctx->DeviceInstanceId, MAX_DEVICE_ID_LEN, DeviceInstanceId, _TRUNCATE);
SetEvent(Ctx->Triggered);
}