Re: [PATCH] md.c - null ptr fixes for 2.4.4

From: Jeff Garzik (jgarzik@mandrakesoft.com)
Date: Thu May 24 2001 - 02:52:19 EST


Praveen Srinivasan wrote:
> @@ -3773,7 +3774,12 @@
> ainfo.spare_disks = 0;
> ainfo.layout = 0;
> ainfo.chunk_size = md_setup_args.chunk[minor];
> - err = set_array_info(mddev, &ainfo);
> + if(mddev==NULL){
> + err=1;
> + }
> + else {
> + err = set_array_info(mddev, &ainfo);
> + }
> for (i = 0; !err && (dev = md_setup_args.devices[minor][i]); i++) {
> dinfo.number = i;
> dinfo.raid_disk = i;
> @@ -3797,9 +3803,12 @@
> if (!err)
> err = do_md_run(mddev);
> if (err) {
> - mddev->sb_dirty = 0;
> - do_md_stop(mddev, 0);
> - printk("md: starting md%d failed\n", minor);
> + if(mddev !=NULL){
> + mddev->sb_dirty = 0;
> + do_md_stop(mddev, 0);
> + }
> +
> + printk("md: starting md%d failed\n", minor);

coding style of changes totally different from surrounding code, and
Documentation/CodingStyle

ditto for other patches... i didn't check all, only several

-- 
Jeff Garzik      | "Are you the police?"
Building 1024    | "No, ma'am.  We're musicians."
MandrakeSoft     |
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu May 31 2001 - 21:00:14 EST