|
@@ -679,6 +679,7 @@ static int send_filled_buffers_to_user(void)
|
|
|
static int nlmsg_seq;
|
|
|
unsigned long flags;
|
|
|
static int rate_limit;
|
|
|
+ void *out;
|
|
|
|
|
|
while (!list_empty(&gwlan_logging.filled_list)
|
|
|
&& !gwlan_logging.exit) {
|
|
@@ -725,7 +726,12 @@ static int send_filled_buffers_to_user(void)
|
|
|
|
|
|
wnl = (tAniNlHdr *) nlh;
|
|
|
wnl->radio = plog_msg->radio;
|
|
|
- memcpy(&wnl->wmsg, plog_msg->logbuf,
|
|
|
+ /* kernel FORTIFY_SOURCE may warn when multiple struct
|
|
|
+ * are copied using memcpy. So, to avoid, assign a
|
|
|
+ * void pointer to the struct and copy using memcpy
|
|
|
+ */
|
|
|
+ out = &wnl->wmsg;
|
|
|
+ memcpy(out, plog_msg->logbuf,
|
|
|
plog_msg->filled_length + sizeof(tAniHdr));
|
|
|
|
|
|
spin_lock_irqsave(&gwlan_logging.spin_lock, flags);
|