Program: 101762
Project: 101762
Buggy source:
/** 
 * @see Remoter#execute(RemoteMethod)
 */
public Document execute(RemoteMethod method) throws RemoterException {
  String methodname=method.getMethodName();
  try {
    if (RemoteConstants.METHOD_GETBIBLES.equals(methodname)) {
      List lbmds=Books.getBooks(BookFilters.getFaster(Books.SPEED_SLOWEST));
      BibleMetaData[] bmds=(BibleMetaData[])lbmds.toArray(new BibleMetaData[lbmds.size()]);
      String[] uids=getUIDs(bmds);
      return Converter.convertBibleMetaDatasToDocument(bmds,uids);
    }
 else     if (RemoteConstants.METHOD_GETDATA.equals(methodname)) {
      String uid=method.getParameter(RemoteConstants.PARAM_BIBLE);
      BibleMetaData bmd=lookupBibleMetaData(uid);
      Bible bible=bmd.getBible();
      String refstr=method.getParameter(RemoteConstants.PARAM_PASSAGE);
      Passage ref=PassageFactory.createPassage(refstr);
      BibleData data=bible.getData(ref);
      SAXEventProvider provider=OsisUtil.getSAXEventProvider(data);
      SAXHandler handler=new SAXHandler();
      provider.provideSAXEvents(handler);
      return handler.getDocument();
    }
 else     if (RemoteConstants.METHOD_FINDPASSAGE.equals(methodname)) {
      String uid=method.getParameter(RemoteConstants.PARAM_BIBLE);
      BibleMetaData bmd=lookupBibleMetaData(uid);
      Bible bible=bmd.getBible();
      String word=method.getParameter(RemoteConstants.PARAM_FINDSTRING);
      boolean match=Boolean.getBoolean(method.getParameter(RemoteConstants.PARAM_FINDMATCH));
      String refstr=method.getParameter(RemoteConstants.PARAM_FINDRANGE);
      Passage range=PassageFactory.createPassage(refstr);
      Search search=new Search(word,match);
      search.setRange(range);
      Passage ref=bible.findPassage(search);
      return Converter.convertPassageToDocument(ref);
    }
 else {
      throw new RemoterException("String_Node_Str" + methodname);
    }
  }
 catch (  RemoterException ex) {
    throw ex;
  }
catch (  Exception ex) {
    throw new RemoterException("String_Node_Str",ex);
  }
}

Fixed version (ground truth):
/** 
 * @see Remoter#execute(RemoteMethod)
 */
public Document execute(RemoteMethod method) throws RemoterException {
  String methodname=method.getMethodName();
  try {
    if (RemoteConstants.METHOD_GETBIBLES.equals(methodname)) {
      List lbmds=Books.getBooks(BookFilters.getFaster(Books.SPEED_SLOWEST));
      BibleMetaData[] bmds=(BibleMetaData[])lbmds.toArray(new BibleMetaData[lbmds.size()]);
      String[] uids=getUIDs(bmds);
      return Converter.convertBibleMetaDatasToDocument(bmds,uids);
    }
 else     if (RemoteConstants.METHOD_GETDATA.equals(methodname)) {
      String uid=method.getParameter(RemoteConstants.PARAM_BIBLE);
      BibleMetaData bmd=lookupBibleMetaData(uid);
      Bible bible=bmd.getBible();
      String refstr=method.getParameter(RemoteConstants.PARAM_PASSAGE);
      Passage ref=PassageFactory.createPassage(refstr);
      BibleData data=bible.getData(ref);
      SAXEventProvider provider=OsisUtil.getSAXEventProvider(data);
      SAXHandler handler=new SAXHandler();
      provider.provideSAXEvents(handler);
      return handler.getDocument();
    }
 else     if (RemoteConstants.METHOD_FINDPASSAGE.equals(methodname)) {
      String uid=method.getParameter(RemoteConstants.PARAM_BIBLE);
      BibleMetaData bmd=lookupBibleMetaData(uid);
      Bible bible=bmd.getBible();
      String word=method.getParameter(RemoteConstants.PARAM_FINDSTRING);
      boolean match=Boolean.getBoolean(method.getParameter(RemoteConstants.PARAM_FINDMATCH));
      String refstr=method.getParameter(RemoteConstants.PARAM_FINDRANGE);
      Passage range=PassageFactory.createPassage(refstr);
      Search search=new Search(word,match);
      search.setRestriction(range);
      Passage ref=bible.findPassage(search);
      return Converter.convertPassageToDocument(ref);
    }
 else {
      throw new RemoterException("String_Node_Str" + methodname);
    }
  }
 catch (  RemoterException ex) {
    throw ex;
  }
catch (  Exception ex) {
    throw new RemoterException("String_Node_Str",ex);
  }
}