diff options
author | rgrimes <rgrimes@FreeBSD.org> | 1993-09-20 06:27:06 +0000 |
---|---|---|
committer | rgrimes <rgrimes@FreeBSD.org> | 1993-09-20 06:27:06 +0000 |
commit | c56db4c78ab571bc91840bb8a394911b9d15e7ee (patch) | |
tree | f8c5b0f4d0503f6438e340adc93b9a4695987d6d /sys/scsi/st.c | |
parent | a1c237516c73326d5fb4f1324a5d18483baaf8e0 (diff) | |
download | FreeBSD-src-c56db4c78ab571bc91840bb8a394911b9d15e7ee.zip FreeBSD-src-c56db4c78ab571bc91840bb8a394911b9d15e7ee.tar.gz |
The dynamically allocated struct's where not getting properly initialized
as malloc memory is NOT zerod. Added bzero's after the malloc calls
to make sure that things are initialized.
>From Julian Elischer
Diffstat (limited to 'sys/scsi/st.c')
-rw-r--r-- | sys/scsi/st.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/scsi/st.c b/sys/scsi/st.c index ed803c7..ea35b92 100644 --- a/sys/scsi/st.c +++ b/sys/scsi/st.c @@ -21,13 +21,13 @@ * 16 Feb 93 Julian Elischer ADDED for SCSI system * 1.15 is the last verion to support MACH and OSF/1 */ -/* $Revision: 1.7 $ */ +/* $Revision: 1.8 $ */ /* * Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992 * major changes by Julian Elischer (julian@jules.dialix.oz.au) May 1993 * - * $Id: st.c,v 1.7 1993/09/05 15:42:22 rgrimes Exp $ + * $Id: st.c,v 1.8 1993/09/07 15:58:00 rgrimes Exp $ */ @@ -255,6 +255,8 @@ struct scsi_switch *scsi_switch; printf("st%d: malloc failed in st.c\n",unit); return(0); } + bzero(st,sizeof(struct st_data)); + /*******************************************************\ * Store information needed to contact our base driver * \*******************************************************/ |