Author: sbruno Date: Wed Jan 28 20:22:48 2015 New Revision: 277853 URL: https://svnweb.freebsd.org/changeset/base/277853
Log: Check for invalid length or more than max length for the interpreter, instead of the validity of the string pointer holding the interpreter. Submitted by: sson Reviewed by: dim MFC after: 3 days Modified: head/usr.sbin/binmiscctl/binmiscctl.c Modified: head/usr.sbin/binmiscctl/binmiscctl.c ============================================================================== --- head/usr.sbin/binmiscctl/binmiscctl.c Wed Jan 28 20:01:21 2015 (r277852) +++ head/usr.sbin/binmiscctl/binmiscctl.c Wed Jan 28 20:22:48 2015 (r277853) @@ -363,7 +363,7 @@ add_cmd(__unused int argc, char *argv[], usage("Error: Missing magic argument"); } - if (!xbe->xbe_interpreter) { + if (!strnlen(xbe->xbe_interpreter, IBE_INTERP_LEN_MAX)) { usage("Error: Missing 'interpreter' argument"); } _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"