Program: 30394
Project: 30394
Buggy source:
/** 
 * Obtain a set of connection validation class names for the database vendor that the jdbc connection pool refers to. This API is used when custom-validation is chosen as the connection validation method, to list the various custom validation implementations available for this dbvendor.
 * @param poolName
 * @return a map containing a VALIDATION_CLASS_NAMES_KEY with a set ofvalidation class names. If VALIDATION_CLASS_NAMES_KEY is null, an  exception has occured and REASON_FAILED_KEY would give the reason why getting connection validation classnames failed.
 */
public Map<String,Object> getValidationClassNames(final String dbVendor){
  final Map<String,Object> result=new HashMap<String,Object>();
  if (mHabitat == null) {
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,false);
    result.put(ConnectorRuntimeAPIProvider.REASON_FAILED_KEY,"String_Node_Str");
    return result;
  }
  try {
    final ConnectorRuntime connRuntime=mHabitat.getComponent(ConnectorRuntime.class,null);
    final Set<String> valClassNames=connRuntime.getValidationClassNames(dbVendor);
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,valClassNames);
  }
 catch (  ComponentException e) {
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,null);
    result.put(ConnectorRuntimeAPIProvider.REASON_FAILED_KEY,ExceptionUtil.toString(e));
  }
catch (  Exception e) {
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,null);
    result.put(ConnectorRuntimeAPIProvider.REASON_FAILED_KEY,ExceptionUtil.toString(e));
  }
  return result;
}

Fixed version (ground truth):
/** 
 * Obtain a set of connection validation class names for the datasource/driver class name that the jdbc connection pool refers to. This API is used when custom-validation is chosen as the connection validation method, to list the various custom validation implementations available.
 * @param className
 * @return a map containing a VALIDATION_CLASS_NAMES_KEY with a set ofvalidation class names. If VALIDATION_CLASS_NAMES_KEY is null, an  exception has occured and REASON_FAILED_KEY would give the reason why getting connection validation classnames failed.
 */
public Map<String,Object> getValidationClassNames(final String className){
  final Map<String,Object> result=new HashMap<String,Object>();
  if (mHabitat == null) {
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,false);
    result.put(ConnectorRuntimeAPIProvider.REASON_FAILED_KEY,"String_Node_Str");
    return result;
  }
  try {
    final ConnectorRuntime connRuntime=mHabitat.getComponent(ConnectorRuntime.class,null);
    final Set<String> valClassNames=connRuntime.getValidationClassNames(className);
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,valClassNames);
  }
 catch (  ComponentException e) {
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,null);
    result.put(ConnectorRuntimeAPIProvider.REASON_FAILED_KEY,ExceptionUtil.toString(e));
  }
catch (  Exception e) {
    result.put(ConnectorRuntimeAPIProvider.VALIDATION_CLASS_NAMES_KEY,null);
    result.put(ConnectorRuntimeAPIProvider.REASON_FAILED_KEY,ExceptionUtil.toString(e));
  }
  return result;
}