lkml.org 
[lkml]   [2014]   [Jul]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectlinux-next: manual merge of the rd-docs tree with the trivial tree
Hi Randy,

Today's linux-next merge of the rd-docs tree got a conflict in
Documentation/laptops/freefall.c between commit d5ae11dc402f ("doc:
hpfall.c: fix missing null-terminate after strncpy call") from the
trivial tree and commit 0af05db576e9 ("Dell kernel driver dell-smo8800
provides same freefall interface as hp_accel so") from the rd-docs tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au

diff --cc Documentation/laptops/freefall.c
index 67084321dab4,aab2ff09e868..000000000000
--- a/Documentation/laptops/freefall.c
+++ b/Documentation/laptops/freefall.c
@@@ -27,8 -33,8 +33,9 @@@ static int set_unload_heads_path(char *

if (strlen(device) <= 5 || strncmp(device, "/dev/", 5) != 0)
return -EINVAL;
- strncpy(devname, device + 5, sizeof(devname));
+ strncpy(devname, device + 5, sizeof(devname) - 1);
+ devname[sizeof(devname) - 1] = '\0';
+ strncpy(device_path, device, sizeof(device_path) - 1);

snprintf(unload_heads_path, sizeof(unload_heads_path) - 1,
"/sys/block/%s/device/unload_heads", devname);
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2014-07-09 10:01    [W:0.068 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site