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

Nicolas Capponi
22.37.2014 6bc38c0e7fad827dc83dedf4ddc0ebed1b4a9095
opendj3-server-dev/src/server/org/opends/server/workflowelement/localbackend/LocalBackendSearchOperation.java
@@ -504,18 +504,19 @@
        }
        // NYI -- Add support for additional controls.
        else if (c.isCritical())
        else if (c.isCritical() && !backendSupportsControl(oid))
        {
          if ((backend == null) || (! backend.supportsControl(oid)))
          {
            throw new DirectoryException(
                           ResultCode.UNAVAILABLE_CRITICAL_EXTENSION,
                           ERR_SEARCH_UNSUPPORTED_CRITICAL_CONTROL.get(oid));
          }
          throw new DirectoryException(
              ResultCode.UNAVAILABLE_CRITICAL_EXTENSION,
              ERR_SEARCH_UNSUPPORTED_CRITICAL_CONTROL.get(oid));
        }
      }
    }
  }
}
  /** Indicates if the backend supports the control corresponding to provided oid. */
  private boolean backendSupportsControl(final String oid)
  {
    return backend != null && backend.supportsControl(oid);
  }
}