Buggy code:
public abstract class Template { public static final String PLAN_SERVICE_IP = "10.131.253.211" ; public static final int PLAN_SERVICE_PORT = 8885 ; private static final String PLAN_SERVICE_URL = String . format ( "http:////%s:%d//globaloptimization?wsdl" , Template . PLAN_SERVICE_IP , Template . PLAN_SERVICE_PORT ) ; private static final String PLAN_SERVICE_NAMESPACE = "http:////ws.sutd.edu.sg//" ; private static final String PLAN_SERVICE_METHOD = "globalOptimization" ; private ServiceExecutionListener listener ; private TemplateFactory . ServiceResolver resolver ; private InstanceCount instanceCount ; private Map < String , Integer > resultNums ; private List < String > serviceSequence ; private long deadline ; private int costRemain ; private Logger logger = Logger . getJADELogger ( this . getClass ( ) . getName ( ) ) ; void setInstanceCount ( TemplateFactory . InstanceCount instanceCount ) { } void setServiceExecutionListener ( ServiceExecutionListener listener ) { } void setServiceResolver ( TemplateFactory . ServiceResolver resolver ) { } public void executeTemplate ( ) { } private void requestTotalTimeCost ( ) { double reliability ; int time ; int cost ; do { time = intInput ( "Please<seq2seq4repair_space>input<seq2seq4repair_space>expected<seq2seq4repair_space>execution<seq2seq4repair_space>time<seq2seq4repair_space>for<seq2seq4repair_space>this<seq2seq4repair_space>template:(s)" ) ; cost = intInput ( "Please<seq2seq4repair_space>input<seq2seq4repair_space>expected<seq2seq4repair_space>cost<seq2seq4repair_space>for<seq2seq4repair_space>this<seq2seq4repair_space>template:(￠)" ) ; showMessage ( "Given<seq2seq4repair_space>Execution<seq2seq4repair_space>Time:%d(s),<seq2seq4repair_space>Cost:%d￠,<seq2seq4repair_space>Assessing<seq2seq4repair_space>Reliability..." , time , cost ) ; reliability = assessReliability ( time , cost ) ; <START_BUG> } while ( requestUserConfirm ( String . format ( "Reliability:<seq2seq4repair_space>%.2f%%.<seq2seq4repair_space>Reinput<seq2seq4repair_space>time<seq2seq4repair_space>and<seq2seq4repair_space>cost?" , reliability ) ) ) ; <END_BUG> setDeadline ( time ) ; this . costRemain = cost ; } private int intInput ( String msg ) { } private double assessReliability ( int time , int cost ) { } private void planTimeCost ( ConcreteService service ) { } private void setDeadline ( int time ) { } private int getTimeRemain ( ) { } private Response invokePlanWS ( Request request ) { } protected abstract void resolveService ( Template . ServiceResolver serviceResolver ) { } protected abstract void execute ( ) { } protected void log ( String msg ) { } protected String requestUserInput ( String format , Object ... args ) { } protected boolean requestUserConfirm ( String format , Object ... args ) { } protected int requestUserChoose ( String format , final String [ ] item , Object ... args ) { } protected void showMessage ( String format , Object ... args ) { } protected class ServiceResolver { public < S > S resolveService ( Class < S > serviceClass ) { } } private class ServiceHandler < T > implements InvocationHandler { private T target ; public T newProxyInstance ( T target ) { } @ Override public synchronized Object invoke ( Object proxy , Method method , Object [ ] args ) throws Throwable { } } private class mServiceExecutionListener implements ServiceExecutionListener { private ServiceExecutionListener listener ; public mServiceExecutionListener ( ServiceExecutionListener listener ) { } @ Override public void onServiceStart ( ConcreteService service , Object [ ] args ) { } @ Override public void onServiceStop ( ConcreteService service ) { } @ Override public void onServiceException ( ConcreteService service , String reason ) { } @ Override public void onTemplateStop ( ) { } @ Override public String onRequestUserInput ( String msg ) { } @ Override public boolean onRequestUserConfirm ( String msg ) { } @ Override public int onRequestUserChoose ( String msg , String [ ] items ) { } @ Override public void onShowMessage ( String msg ) { } } }

Fix:
} while ( requestUserConfirm ( "Reliability:<seq2seq4repair_space>%.2f%%.<seq2seq4repair_space>Reinput<seq2seq4repair_space>time<seq2seq4repair_space>and<seq2seq4repair_space>cost?" , reliability ) ) ;