mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

jvergara
14.52.2009 f40316d425413e23a8ad77aa268e3d1bed977e0e
Apply the same fix done for issue 4273 (server does not work as service if Windows UAC enabled in Windows Server 2008) to Windows 7.

1 files modified
23 ■■■■■ changed files
opends/src/server/org/opends/server/util/SetupUtils.java 23 ●●●●● patch | view | raw | blame | history
opends/src/server/org/opends/server/util/SetupUtils.java
@@ -316,6 +316,27 @@
  }
  /**
   * Indicates whether the underlying operating system is Windows 7.
   *
   * @return  {@code true} if the underlying operating system is Windows 7, or
   * {@code false} if not.
   */
  public static boolean isWindows7()
  {
    boolean isWindows7;
    String os = System.getProperty("os.name");
    if (os != null)
    {
      isWindows7 = (os.toLowerCase().indexOf("windows 7") != -1);
    }
    else
    {
      isWindows7 = false;
    }
    return isWindows7;
  }
  /**
   * Indicates whether the underlying operating system has UAC (User Access
   * Control).
   *
@@ -324,7 +345,7 @@
   */
  public static boolean hasUAC()
  {
    return SetupUtils.isVista() || SetupUtils.isWindows2008();
    return isVista() || isWindows2008() || isWindows7();
  }
  /**