diff for duplicates of <87lj1zpf8k.fsf@ti.com> diff --git a/a/1.txt b/N1/1.txt index 200b259..d3a2898 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -21,14 +21,14 @@ Kevin > --- a/arch/arm/mach-omap2/smartreflex.c > +++ b/arch/arm/mach-omap2/smartreflex.c > @@ -260,9 +260,11 @@ static int sr_late_init(struct omap_sr *sr_info) -> if (sr_class->class_type = SR_CLASS2 && +> if (sr_class->class_type == SR_CLASS2 && > sr_class->notify_flags && sr_info->irq) { > > - name = kzalloc(SMARTREFLEX_NAME_LEN + 1, GFP_KERNEL); > - strcpy(name, "sr_"); > - strcat(name, sr_info->voltdm->name); > + name = kasprintf(GFP_KERNEL, "sr_%s", sr_info->voltdm->name); -> + if (name = NULL) { +> + if (name == NULL) { > + ret = -ENOMEM; > + goto error; > + } diff --git a/a/content_digest b/N1/content_digest index f43577b..74c299e 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -3,8 +3,15 @@ "ref\020110119125721.GA9203@albatros\0" "From\0Kevin Hilman <khilman@ti.com>\0" "Subject\0Re: [PATCH v2] arm: mach-omap2: potential NULL dereference\0" - "Date\0Tue, 01 Feb 2011 22:22:19 +0000\0" - "To\0linux-arm-kernel@lists.infradead.org\0" + "Date\0Tue, 01 Feb 2011 14:22:19 -0800\0" + "To\0Vasiliy Kulikov <segoon@openwall.com>\0" + "Cc\0linux-kernel@vger.kernel.org" + walter harms <wharms@bfs.de> + kernel-janitors@vger.kernel.org + Tony Lindgren <tony@atomide.com> + Russell King <linux@arm.linux.org.uk> + linux-omap@vger.kernel.org + " linux-arm-kernel@lists.infradead.org\0" "\00:1\0" "b\0" "Vasiliy Kulikov <segoon@openwall.com> writes:\n" @@ -30,14 +37,14 @@ "> --- a/arch/arm/mach-omap2/smartreflex.c\n" "> +++ b/arch/arm/mach-omap2/smartreflex.c\n" "> @@ -260,9 +260,11 @@ static int sr_late_init(struct omap_sr *sr_info)\n" - "> \tif (sr_class->class_type = SR_CLASS2 &&\n" + "> \tif (sr_class->class_type == SR_CLASS2 &&\n" "> \t\tsr_class->notify_flags && sr_info->irq) {\n" "> \n" "> -\t\tname = kzalloc(SMARTREFLEX_NAME_LEN + 1, GFP_KERNEL);\n" "> -\t\tstrcpy(name, \"sr_\");\n" "> -\t\tstrcat(name, sr_info->voltdm->name);\n" "> +\t\tname = kasprintf(GFP_KERNEL, \"sr_%s\", sr_info->voltdm->name);\n" - "> +\t\tif (name = NULL) {\n" + "> +\t\tif (name == NULL) {\n" "> +\t\t\tret = -ENOMEM;\n" "> +\t\t\tgoto error;\n" "> +\t\t}\n" @@ -45,4 +52,4 @@ "> \t\t\t\t0, name, (void *)sr_info);\n" "> \t\tif (ret)" -3845f2e43fcdb260da282efde9ddc2e46db065e7d770b16531a96b6a099cd999 +510da2cc45c94ca7a9188f75c2efb8be12a011466473e74bce1fca29124afab1
diff --git a/a/1.txt b/N2/1.txt index 200b259..d3a2898 100644 --- a/a/1.txt +++ b/N2/1.txt @@ -21,14 +21,14 @@ Kevin > --- a/arch/arm/mach-omap2/smartreflex.c > +++ b/arch/arm/mach-omap2/smartreflex.c > @@ -260,9 +260,11 @@ static int sr_late_init(struct omap_sr *sr_info) -> if (sr_class->class_type = SR_CLASS2 && +> if (sr_class->class_type == SR_CLASS2 && > sr_class->notify_flags && sr_info->irq) { > > - name = kzalloc(SMARTREFLEX_NAME_LEN + 1, GFP_KERNEL); > - strcpy(name, "sr_"); > - strcat(name, sr_info->voltdm->name); > + name = kasprintf(GFP_KERNEL, "sr_%s", sr_info->voltdm->name); -> + if (name = NULL) { +> + if (name == NULL) { > + ret = -ENOMEM; > + goto error; > + } diff --git a/a/content_digest b/N2/content_digest index f43577b..2e4ef66 100644 --- a/a/content_digest +++ b/N2/content_digest @@ -1,9 +1,9 @@ "ref\01295258922-31242-1-git-send-email-segoon@openwall.com\0" "ref\04D341C35.80506@bfs.de\0" "ref\020110119125721.GA9203@albatros\0" - "From\0Kevin Hilman <khilman@ti.com>\0" - "Subject\0Re: [PATCH v2] arm: mach-omap2: potential NULL dereference\0" - "Date\0Tue, 01 Feb 2011 22:22:19 +0000\0" + "From\0khilman@ti.com (Kevin Hilman)\0" + "Subject\0[PATCH v2] arm: mach-omap2: potential NULL dereference\0" + "Date\0Tue, 01 Feb 2011 14:22:19 -0800\0" "To\0linux-arm-kernel@lists.infradead.org\0" "\00:1\0" "b\0" @@ -30,14 +30,14 @@ "> --- a/arch/arm/mach-omap2/smartreflex.c\n" "> +++ b/arch/arm/mach-omap2/smartreflex.c\n" "> @@ -260,9 +260,11 @@ static int sr_late_init(struct omap_sr *sr_info)\n" - "> \tif (sr_class->class_type = SR_CLASS2 &&\n" + "> \tif (sr_class->class_type == SR_CLASS2 &&\n" "> \t\tsr_class->notify_flags && sr_info->irq) {\n" "> \n" "> -\t\tname = kzalloc(SMARTREFLEX_NAME_LEN + 1, GFP_KERNEL);\n" "> -\t\tstrcpy(name, \"sr_\");\n" "> -\t\tstrcat(name, sr_info->voltdm->name);\n" "> +\t\tname = kasprintf(GFP_KERNEL, \"sr_%s\", sr_info->voltdm->name);\n" - "> +\t\tif (name = NULL) {\n" + "> +\t\tif (name == NULL) {\n" "> +\t\t\tret = -ENOMEM;\n" "> +\t\t\tgoto error;\n" "> +\t\t}\n" @@ -45,4 +45,4 @@ "> \t\t\t\t0, name, (void *)sr_info);\n" "> \t\tif (ret)" -3845f2e43fcdb260da282efde9ddc2e46db065e7d770b16531a96b6a099cd999 +8a97e81f44e9fcc37203a0578c8f8eb56f8a1e45eff841ef194b7fb679e7a4e3
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.