Program: 60515
Project: 60515
Buggy source:
@Override public void execute(final Input input){
  LOG.debug("String_Node_Str");
  LOG.debug("String_Node_Str",input.getOption());
  LOG.debug("String_Node_Str");
  for (  final String parameter : input.getParameters()) {
    LOG.debug("String_Node_Str" + parameter);
  }
  final String[] parameters=input.getParameters();
  if (StringUtils.isBlank(input.getOption())) {
    input.setOption(Options.HELP.getOptionName());
  }
  final ConfigurationService configurationService=SyncopeServices.get(ConfigurationService.class);
switch (Options.fromName(input.getOption())) {
case LIST:
    try {
      final ConfTO confTO=configurationService.list();
      System.out.println("String_Node_Str" + confTO.getKey());
      System.out.println("String_Node_Str");
      System.out.println("String_Node_Str");
      for (      final AttrTO attrTO : confTO.getPlainAttrMap().values()) {
        System.out.println("String_Node_Str" + attrTO.getSchema());
        System.out.println("String_Node_Str" + attrTO.getValues());
        System.out.println("String_Node_Str" + attrTO.isReadonly());
      }
      System.out.println("String_Node_Str");
      System.out.println("String_Node_Str");
      for (      final AttrTO attrTO : confTO.getDerAttrMap().values()) {
        System.out.println("String_Node_Str" + attrTO.getSchema());
        System.out.println("String_Node_Str" + attrTO.getValues());
        System.out.println("String_Node_Str" + attrTO.isReadonly());
      }
      System.out.println("String_Node_Str");
      System.out.println("String_Node_Str");
      for (      final AttrTO attrTO : confTO.getVirAttrMap().values()) {
        System.out.println("String_Node_Str" + attrTO.getSchema());
        System.out.println("String_Node_Str" + attrTO.getValues());
        System.out.println("String_Node_Str" + attrTO.isReadonly());
      }
      System.out.println("String_Node_Str");
    }
 catch (    final Exception ex) {
      UsageMessages.printErrorMessage(ex.getMessage());
      break;
    }
  break;
case READ:
final String readErrorMessage=UsageMessages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
AttrTO attrTO;
for (final String parameter : parameters) {
  try {
    attrTO=configurationService.get(parameter);
    System.out.println("String_Node_Str" + attrTO.getSchema());
    System.out.println("String_Node_Str" + attrTO.getValues());
    System.out.println("String_Node_Str" + attrTO.isReadonly());
    System.out.println("String_Node_Str");
  }
 catch (  final SyncopeClientException|WebServiceException ex) {
    if (ex.getMessage().startsWith("String_Node_Str")) {
      UsageMessages.printErrorMessage("String_Node_Str" + parameters[0] + "String_Node_Str");
    }
 else     if (ex.getMessage().startsWith("String_Node_Str")) {
      UsageMessages.printErrorMessage("String_Node_Str" + parameters[0]);
    }
 else {
      UsageMessages.printErrorMessage(ex.getMessage());
    }
    break;
  }
}
}
 else {
System.out.println(readErrorMessage);
}
break;
case UPDATE:
final String updateErrorMessage=UsageMessages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
Input.PairParameter pairParameter=null;
AttrTO attrTO;
for (final String parameter : parameters) {
try {
pairParameter=input.toPairParameter(parameter);
attrTO=configurationService.get(pairParameter.getKey());
attrTO.getValues().clear();
attrTO.getValues().add(pairParameter.getValue());
configurationService.set(attrTO);
System.out.println("String_Node_Str" + attrTO.getSchema() + "String_Node_Str");
System.out.println("String_Node_Str" + attrTO.getValues());
System.out.println("String_Node_Str" + attrTO.isReadonly());
System.out.println("String_Node_Str");
}
 catch (final IllegalArgumentException ex) {
UsageMessages.printErrorMessage(ex.getMessage(),updateErrorMessage);
break;
}
catch (final SyncopeClientException|WebServiceException ex) {
if (ex.getMessage().startsWith("String_Node_Str")) {
UsageMessages.printErrorMessage("String_Node_Str" + pairParameter.getKey() + "String_Node_Str");
}
 else if (ex.getMessage().startsWith("String_Node_Str")) {
UsageMessages.printErrorMessage(pairParameter.getValue() + "String_Node_Str" + pairParameter.getKey());
}
 else if (ex.getMessage().startsWith("String_Node_Str")) {
UsageMessages.printErrorMessage("String_Node_Str" + parameters[0]);
}
 else {
UsageMessages.printErrorMessage(ex.getMessage());
}
break;
}
}
}
 else {
System.out.println(updateErrorMessage);
}
break;
case CREATE:
final String createErrorMessage=UsageMessages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
Input.PairParameter pairParameter=null;
AttrTO attrTO;
for (final String parameter : parameters) {
try {
pairParameter=input.toPairParameter(parameter);
attrTO=new AttrTO();
attrTO.setSchema(pairParameter.getKey());
attrTO.getValues().add(pairParameter.getValue());
configurationService.set(attrTO);
System.out.println("String_Node_Str" + attrTO.getSchema() + "String_Node_Str");
System.out.println("String_Node_Str" + attrTO.getValues());
System.out.println("String_Node_Str" + attrTO.isReadonly());
System.out.println("String_Node_Str");
}
 catch (final IllegalArgumentException ex) {
UsageMessages.printErrorMessage(ex.getMessage(),createErrorMessage);
break;
}
catch (final SyncopeClientException|WebServiceException ex) {
if (ex.getMessage().startsWith("String_Node_Str")) {
UsageMessages.printErrorMessage("String_Node_Str" + pairParameter.getKey() + "String_Node_Str");
}
 else {
UsageMessages.printErrorMessage(ex.getMessage());
}
break;
}
}
}
 else {
System.out.println(createErrorMessage);
}
break;
case DELETE:
final String deleteErrorMessage=UsageMessages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
for (final String parameter : parameters) {
try {
configurationService.delete(parameter);
System.out.println("String_Node_Str" + parameter + "String_Node_Str");
}
 catch (final SyncopeClientException|WebServiceException ex) {
if (ex.getMessage().startsWith("String_Node_Str")) {
UsageMessages.printErrorMessage("String_Node_Str" + parameter + "String_Node_Str");
}
 else if (ex.getMessage().startsWith("String_Node_Str")) {
UsageMessages.printErrorMessage("String_Node_Str",parameter);
}
 else {
UsageMessages.printErrorMessage(ex.getMessage());
}
break;
}
}
}
 else {
System.out.println(deleteErrorMessage);
}
break;
case EXPORT:
final String exportErrorMessage=UsageMessages.optionCommandMessage("String_Node_Str");
if (parameters.length == 1) {
try {
XMLUtils.createXMLFile((SequenceInputStream)configurationService.export().getEntity(),parameters[0] + EXPORT_FILE_NAME);
System.out.println("String_Node_Str" + parameters[0] + EXPORT_FILE_NAME+ "String_Node_Str");
}
 catch (final IOException ex) {
UsageMessages.printErrorMessage(ex.getMessage());
}
catch (ParserConfigurationException|SAXException|TransformerConfigurationException ex) {
LOG.error("String_Node_Str",parameters[0],ex);
UsageMessages.printErrorMessage("String_Node_Str" + parameters[0] + EXPORT_FILE_NAME+ "String_Node_Str"+ ex.getMessage());
break;
}
catch (final TransformerException ex) {
LOG.error("String_Node_Str",parameters[0],ex);
if (ex.getCause() instanceof FileNotFoundException) {
UsageMessages.printErrorMessage("String_Node_Str" + parameters[0]);
}
 else {
UsageMessages.printErrorMessage("String_Node_Str" + parameters[0] + EXPORT_FILE_NAME+ "String_Node_Str"+ ex.getMessage());
}
break;
}
catch (final SyncopeClientException ex) {
LOG.error("String_Node_Str",ex);
UsageMessages.printErrorMessage("String_Node_Str" + ex.getMessage());
break;
}
}
 else {
System.out.println(exportErrorMessage);
}
break;
case HELP:
System.out.println(HELP_MESSAGE);
break;
default :
System.out.println(input.getOption() + "String_Node_Str");
System.out.println("String_Node_Str");
System.out.println(HELP_MESSAGE);
break;
}
}

Fixed version (ground truth):
@Override public void execute(final Input input){
  LOG.debug("String_Node_Str");
  LOG.debug("String_Node_Str",input.getOption());
  LOG.debug("String_Node_Str");
  for (  final String parameter : input.getParameters()) {
    LOG.debug("String_Node_Str" + parameter);
  }
  final String[] parameters=input.getParameters();
  if (StringUtils.isBlank(input.getOption())) {
    input.setOption(Options.HELP.getOptionName());
  }
  final ConfigurationService configurationService=SyncopeServices.get(ConfigurationService.class);
switch (Options.fromName(input.getOption())) {
case LIST:
    try {
      final ConfTO confTO=configurationService.list();
      System.out.println("String_Node_Str" + confTO.getKey());
      System.out.println("String_Node_Str");
      System.out.println("String_Node_Str");
      for (      final AttrTO attrTO : confTO.getPlainAttrMap().values()) {
        System.out.println("String_Node_Str" + attrTO.getSchema());
        System.out.println("String_Node_Str" + attrTO.getValues());
        System.out.println("String_Node_Str" + attrTO.isReadonly());
      }
      System.out.println("String_Node_Str");
      System.out.println("String_Node_Str");
      for (      final AttrTO attrTO : confTO.getDerAttrMap().values()) {
        System.out.println("String_Node_Str" + attrTO.getSchema());
        System.out.println("String_Node_Str" + attrTO.getValues());
        System.out.println("String_Node_Str" + attrTO.isReadonly());
      }
      System.out.println("String_Node_Str");
      System.out.println("String_Node_Str");
      for (      final AttrTO attrTO : confTO.getVirAttrMap().values()) {
        System.out.println("String_Node_Str" + attrTO.getSchema());
        System.out.println("String_Node_Str" + attrTO.getValues());
        System.out.println("String_Node_Str" + attrTO.isReadonly());
      }
      System.out.println("String_Node_Str");
    }
 catch (    final Exception ex) {
      Messages.printMessage(ex.getMessage());
      break;
    }
  break;
case READ:
final String readErrorMessage=Messages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
AttrTO attrTO;
for (final String parameter : parameters) {
  try {
    attrTO=configurationService.get(parameter);
    System.out.println("String_Node_Str" + attrTO.getSchema());
    System.out.println("String_Node_Str" + attrTO.getValues());
    System.out.println("String_Node_Str" + attrTO.isReadonly());
    System.out.println("String_Node_Str");
  }
 catch (  final SyncopeClientException|WebServiceException ex) {
    if (ex.getMessage().startsWith("String_Node_Str")) {
      Messages.printMessage("String_Node_Str" + parameters[0] + "String_Node_Str");
    }
 else     if (ex.getMessage().startsWith("String_Node_Str")) {
      Messages.printMessage("String_Node_Str" + parameters[0]);
    }
 else {
      Messages.printMessage(ex.getMessage());
    }
    break;
  }
}
}
 else {
System.out.println(readErrorMessage);
}
break;
case UPDATE:
final String updateErrorMessage=Messages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
Input.PairParameter pairParameter=null;
AttrTO attrTO;
for (final String parameter : parameters) {
try {
pairParameter=input.toPairParameter(parameter);
attrTO=configurationService.get(pairParameter.getKey());
attrTO.getValues().clear();
attrTO.getValues().add(pairParameter.getValue());
configurationService.set(attrTO);
System.out.println("String_Node_Str" + attrTO.getSchema() + "String_Node_Str");
System.out.println("String_Node_Str" + attrTO.getValues());
System.out.println("String_Node_Str" + attrTO.isReadonly());
System.out.println("String_Node_Str");
}
 catch (final IllegalArgumentException ex) {
Messages.printMessage(ex.getMessage(),updateErrorMessage);
break;
}
catch (final SyncopeClientException|WebServiceException ex) {
if (ex.getMessage().startsWith("String_Node_Str")) {
Messages.printMessage("String_Node_Str" + pairParameter.getKey() + "String_Node_Str");
}
 else if (ex.getMessage().startsWith("String_Node_Str")) {
Messages.printMessage(pairParameter.getValue() + "String_Node_Str" + pairParameter.getKey());
}
 else if (ex.getMessage().startsWith("String_Node_Str")) {
Messages.printMessage("String_Node_Str" + parameters[0]);
}
 else {
Messages.printMessage(ex.getMessage());
}
break;
}
}
}
 else {
System.out.println(updateErrorMessage);
}
break;
case CREATE:
final String createErrorMessage=Messages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
Input.PairParameter pairParameter=null;
AttrTO attrTO;
for (final String parameter : parameters) {
try {
pairParameter=input.toPairParameter(parameter);
attrTO=new AttrTO();
attrTO.setSchema(pairParameter.getKey());
attrTO.getValues().add(pairParameter.getValue());
configurationService.set(attrTO);
System.out.println("String_Node_Str" + attrTO.getSchema() + "String_Node_Str");
System.out.println("String_Node_Str" + attrTO.getValues());
System.out.println("String_Node_Str" + attrTO.isReadonly());
System.out.println("String_Node_Str");
}
 catch (final IllegalArgumentException ex) {
Messages.printMessage(ex.getMessage(),createErrorMessage);
break;
}
catch (final SyncopeClientException|WebServiceException ex) {
if (ex.getMessage().startsWith("String_Node_Str")) {
Messages.printMessage("String_Node_Str" + pairParameter.getKey() + "String_Node_Str");
}
 else {
Messages.printMessage(ex.getMessage());
}
break;
}
}
}
 else {
System.out.println(createErrorMessage);
}
break;
case DELETE:
final String deleteErrorMessage=Messages.optionCommandMessage("String_Node_Str");
if (parameters.length >= 1) {
for (final String parameter : parameters) {
try {
configurationService.delete(parameter);
System.out.println("String_Node_Str" + parameter + "String_Node_Str");
}
 catch (final SyncopeClientException|WebServiceException ex) {
if (ex.getMessage().startsWith("String_Node_Str")) {
Messages.printMessage("String_Node_Str" + parameter + "String_Node_Str");
}
 else if (ex.getMessage().startsWith("String_Node_Str")) {
Messages.printMessage("String_Node_Str",parameter);
}
 else {
Messages.printMessage(ex.getMessage());
}
break;
}
}
}
 else {
System.out.println(deleteErrorMessage);
}
break;
case EXPORT:
final String exportErrorMessage=Messages.optionCommandMessage("String_Node_Str");
if (parameters.length == 1) {
try {
XMLUtils.createXMLFile((SequenceInputStream)configurationService.export().getEntity(),parameters[0] + EXPORT_FILE_NAME);
System.out.println("String_Node_Str" + parameters[0] + EXPORT_FILE_NAME+ "String_Node_Str");
}
 catch (final IOException ex) {
Messages.printMessage(ex.getMessage());
}
catch (ParserConfigurationException|SAXException|TransformerConfigurationException ex) {
LOG.error("String_Node_Str",parameters[0],ex);
Messages.printMessage("String_Node_Str" + parameters[0] + EXPORT_FILE_NAME+ "String_Node_Str"+ ex.getMessage());
break;
}
catch (final TransformerException ex) {
LOG.error("String_Node_Str",parameters[0],ex);
if (ex.getCause() instanceof FileNotFoundException) {
Messages.printMessage("String_Node_Str" + parameters[0]);
}
 else {
Messages.printMessage("String_Node_Str" + parameters[0] + EXPORT_FILE_NAME+ "String_Node_Str"+ ex.getMessage());
}
break;
}
catch (final SyncopeClientException ex) {
LOG.error("String_Node_Str",ex);
Messages.printMessage("String_Node_Str" + ex.getMessage());
break;
}
}
 else {
System.out.println(exportErrorMessage);
}
break;
case HELP:
System.out.println(HELP_MESSAGE);
break;
default :
System.out.println(input.getOption() + "String_Node_Str");
System.out.println("String_Node_Str");
System.out.println(HELP_MESSAGE);
break;
}
}