Author: dteske
Date: Mon Dec 12 17:58:43 2016
New Revision: 309900
URL: https://svnweb.freebsd.org/changeset/base/309900

Log:
  MFC r307402: Guard against bad service name argument(s) to load_rc_config()

Modified:
  stable/10/usr.sbin/bsdconfig/share/sysrc.subr
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.sbin/bsdconfig/share/sysrc.subr
==============================================================================
--- stable/10/usr.sbin/bsdconfig/share/sysrc.subr       Mon Dec 12 17:56:56 
2016        (r309899)
+++ stable/10/usr.sbin/bsdconfig/share/sysrc.subr       Mon Dec 12 17:58:43 
2016        (r309900)
@@ -256,7 +256,9 @@ f_sysrc_service_configs()
                        last_name=
                        print_name() {
                                local name="$1"
-                               [ "$name" = "$last_name" ] && return
+                               case "$name" in
+                               ""|.|..|*/*|"$last_name") return ;;
+                               esac
                                echo "$name" >&9
                                last_name="$name"
                        }
_______________________________________________
svn-src-stable-10@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"

Reply via email to