lkml.org 
[lkml]   [2017]   [Jul]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/9] mm, page_alloc: rip out ZONELIST_ORDER_ZONE
On Fri, Jul 14, 2017 at 01:56:16PM +0100, Mel Gorman wrote:
> > if (!write) {
> > - int len = sizeof("Default");
> > - if (copy_to_user(buffer, "Default", len))
> > + int len = sizeof("Node");
> > + if (copy_to_user(buffer, "Node", len))
> > return -EFAULT;
>
> Ok for the name. But what's with using sizeof?

Bah, sizeof static compile-time string versus char *. Never mind.

--
Mel Gorman
SUSE Labs

\
 
 \ /
  Last update: 2017-07-14 15:02    [W:1.835 / U:1.448 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site