Author: ray
Date: Thu May 22 09:31:18 2014
New Revision: 266540
URL: http://svnweb.freebsd.org/changeset/base/266540

Log:
  Proper fix of VT_LOCKSWITCH ioctl.
  
  Sponsored by: The FreeBSD Foundation

Modified:
  head/sys/dev/vt/vt_core.c

Modified: head/sys/dev/vt/vt_core.c
==============================================================================
--- head/sys/dev/vt/vt_core.c   Thu May 22 09:28:36 2014        (r266539)
+++ head/sys/dev/vt/vt_core.c   Thu May 22 09:31:18 2014        (r266540)
@@ -1815,9 +1815,9 @@ skip_thunk:
        case VT_LOCKSWITCH:
                /* TODO: Check current state, switching can be in progress. */
                if ((*(int *)data) == 0x01)
-                       vw->vw_flags &= ~VWF_VTYLOCK;
-               else if ((*(int *)data) == 0x02)
                        vw->vw_flags |= VWF_VTYLOCK;
+               else if ((*(int *)data) == 0x02)
+                       vw->vw_flags &= ~VWF_VTYLOCK;
                else
                        return (EINVAL);
                return (0);
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to