From 7cbe0dbf398c50ef6648babc1c307f526fcbd037 Mon Sep 17 00:00:00 2001 From: Kano Date: Thu, 19 Sep 2013 23:23:36 +1000 Subject: [PATCH] klondike use a memcpy --- driver-klondike.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/driver-klondike.c b/driver-klondike.c index 0ebdd7aa..78f9beca 100644 --- a/driver-klondike.c +++ b/driver-klondike.c @@ -172,7 +172,7 @@ static bool klondike_get_stats(struct cgpu_info *klncgpu) for (dev = 0; dev <= slaves; dev++) { char *reply = SendCmdGetReply(klncgpu, 'S', dev, 0, NULL); if (reply != NULL) - klninfo->status[dev] = *(WORKSTATUS *)(reply+2); + memcpy((void *)(&(klninfo->status[dev])), reply+2, sizeof(klninfo->status[dev])); } wr_unlock(&(klninfo->stat_lock));