projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1a81a2e
)
isdn: use strlcpy() instead strcpy()
author
Dan Carpenter
<dan.carpenter@oracle.com>
Mon, 16 Dec 2013 13:56:23 +0000
(16:56 +0300)
committer
David S. Miller
<davem@davemloft.net>
Wed, 18 Dec 2013 22:53:59 +0000
(17:53 -0500)
I don't think the in-kernel drivers ever hit this strcpy() so this
doesn't change how the code works. But strlcpy() is safer.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/isdn/sc/event.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/isdn/sc/event.c
b/drivers/isdn/sc/event.c
index 717003a3bdf4957835f43eab78eff4f8abc62f5e..833d96c2cf92578a96efc72e18205d63101d9f03 100644
(file)
--- a/
drivers/isdn/sc/event.c
+++ b/
drivers/isdn/sc/event.c
@@
-57,7
+57,7
@@
int indicate_status(int card, int event, ulong Channel, char *Data)
memcpy(&cmd.parm.setup, Data, sizeof(cmd.parm.setup));
break;
default:
- str
cpy(cmd.parm.num, Data
);
+ str
lcpy(cmd.parm.num, Data, sizeof(cmd.parm.num)
);
}
}