summaryrefslogtreecommitdiffstats
path: root/drivers/video/au1100fb.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-09-24 12:59:11 +0200
committerIngo Molnar <mingo@elte.hu>2009-09-24 12:59:18 +0200
commitd2ff6de537c61a0f05731c6679f3e1abc2d95e68 (patch)
tree821aa38121f57a9d5419388ef10ea6f3aa445d4d /drivers/video/au1100fb.c
parente23a8b6a8f319c0f08b6ccef2dccbb37e7603dc2 (diff)
parenta724eada8c2a7b62463b73ccf73fd0bb6e928aeb (diff)
downloadblackbird-op-linux-d2ff6de537c61a0f05731c6679f3e1abc2d95e68.tar.gz
blackbird-op-linux-d2ff6de537c61a0f05731c6679f3e1abc2d95e68.zip
Merge branch 'linus' into x86/urgent
Merge reason: Queueing up dependent early-printk fix. Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/video/au1100fb.c')
-rw-r--r--drivers/video/au1100fb.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/video/au1100fb.c b/drivers/video/au1100fb.c
index 378f27745a1d..a699aab63820 100644
--- a/drivers/video/au1100fb.c
+++ b/drivers/video/au1100fb.c
@@ -715,8 +715,11 @@ int au1100fb_setup(char *options)
}
/* Mode option (only option that start with digit) */
else if (isdigit(this_opt[0])) {
- mode = kmalloc(strlen(this_opt) + 1, GFP_KERNEL);
- strncpy(mode, this_opt, strlen(this_opt) + 1);
+ mode = kstrdup(this_opt, GFP_KERNEL);
+ if (!mode) {
+ print_err("memory allocation failed");
+ return -ENOMEM;
+ }
}
/* Unsupported option */
else {
OpenPOWER on IntegriCloud