svn commit: r341633 - stable/10/sys/security/audit

Andriy Gapon avg at FreeBSD.org
Thu Dec 6 13:32:52 UTC 2018


Author: avg
Date: Thu Dec  6 13:32:51 2018
New Revision: 341633
URL: https://svnweb.freebsd.org/changeset/base/341633

Log:
  MFC r336641: fix incorrect operator in the AUDITPIPE_SET_QLIMIT bounds check
  
  PR:		229983

Modified:
  stable/10/sys/security/audit/audit_pipe.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/security/audit/audit_pipe.c
==============================================================================
--- stable/10/sys/security/audit/audit_pipe.c	Thu Dec  6 12:34:34 2018	(r341632)
+++ stable/10/sys/security/audit/audit_pipe.c	Thu Dec  6 13:32:51 2018	(r341633)
@@ -800,7 +800,7 @@ audit_pipe_ioctl(struct cdev *dev, u_long cmd, caddr_t
 
 	case AUDITPIPE_SET_QLIMIT:
 		/* Lockless integer write. */
-		if (*(u_int *)data >= AUDIT_PIPE_QLIMIT_MIN ||
+		if (*(u_int *)data >= AUDIT_PIPE_QLIMIT_MIN &&
 		    *(u_int *)data <= AUDIT_PIPE_QLIMIT_MAX) {
 			ap->ap_qlimit = *(u_int *)data;
 			error = 0;


More information about the svn-src-stable mailing list