Author: emaste
Date: Wed Jan  3 19:28:13 2018
New Revision: 327529
URL: https://svnweb.freebsd.org/changeset/base/327529

Log:
  ath: fix possible memory disclosure in ioctl handler
  
  Submitted by: Domagoj Stolfa <domagoj.sto...@gmail.com>
  MFC after:    1 week

Modified:
  head/sys/dev/ath/if_ath_ioctl.c

Modified: head/sys/dev/ath/if_ath_ioctl.c
==============================================================================
--- head/sys/dev/ath/if_ath_ioctl.c     Wed Jan  3 19:24:57 2018        
(r327528)
+++ head/sys/dev/ath/if_ath_ioctl.c     Wed Jan  3 19:28:13 2018        
(r327529)
@@ -197,7 +197,7 @@ ath_ioctl_diag(struct ath_softc *sc, struct ath_diag *
                 * pointer for us to use below in reclaiming the buffer;
                 * may want to be more defensive.
                 */
-               outdata = malloc(outsize, M_TEMP, M_NOWAIT);
+               outdata = malloc(outsize, M_TEMP, M_NOWAIT | M_ZERO);
                if (outdata == NULL) {
                        error = ENOMEM;
                        goto bad;
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to