Program: 91131
Project: 91131
Buggy source:
@Override protected void onHandleIntent(@Nullable Intent intent){
  Log.i(LOG_TAG,"String_Node_Str");
  if (intent != null && intent.getAction() != null) {
    String from, to, destAddress;
    double amount;
switch (intent.getAction()) {
case ACTION_GET_CURRENCIES:
      if (currencies == null) {
        loadCurrencies();
      }
    if (currencies == null || currencies.size() == 0) {
      Intent errorIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
      LocalBroadcastManager.getInstance(this).sendBroadcast(errorIntent);
      break;
    }
  Intent currenciesIntent=new Intent(ChangellyService.INFO_CURRENCIES,null,this,ChangellyService.class);
currenciesIntent.putExtra(CURRENCIES,currencies.toArray());
currenciesIntent.putStringArrayListExtra(CURRENCIES,new ArrayList<>(currencies));
LocalBroadcastManager.getInstance(this).sendBroadcast(currenciesIntent);
break;
case ACTION_GET_MIN_EXCHANGE:
from=intent.getStringExtra(FROM);
to=intent.getStringExtra(TO);
double min=getMinAmount(from,to);
if (min == -1) {
Intent errorIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
LocalBroadcastManager.getInstance(this).sendBroadcast(errorIntent);
return;
}
Intent minAmountIntent=new Intent(ChangellyService.INFO_MIN_AMOUNT,null,this,ChangellyService.class);
minAmountIntent.putExtra(FROM,from);
minAmountIntent.putExtra(TO,to);
minAmountIntent.putExtra(AMOUNT,min);
LocalBroadcastManager.getInstance(this).sendBroadcast(minAmountIntent);
break;
case ACTION_GET_EXCHANGE_AMOUNT:
from=intent.getStringExtra(FROM);
to=intent.getStringExtra(TO);
amount=intent.getDoubleExtra(AMOUNT,0);
double offer=getExchangeAmount(from,to,amount);
if (offer == -1) {
Intent errorIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
LocalBroadcastManager.getInstance(this).sendBroadcast(errorIntent);
return;
}
Intent exchangeAmountIntent=new Intent(ChangellyService.INFO_EXCH_AMOUNT,null,this,ChangellyService.class);
exchangeAmountIntent.putExtra(FROM,from);
exchangeAmountIntent.putExtra(TO,to);
exchangeAmountIntent.putExtra(AMOUNT,offer);
LocalBroadcastManager.getInstance(this).sendBroadcast(exchangeAmountIntent);
break;
case ACTION_CREATE_TRANSACTION:
from=intent.getStringExtra(FROM);
to=intent.getStringExtra(TO);
amount=intent.getDoubleExtra(AMOUNT,0);
destAddress=intent.getStringExtra(DESTADDRESS);
ChangellyTransactionOffer res=createTransaction(from,to,amount,destAddress);
Intent transactionIntent;
if (res == null) {
transactionIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
}
 else {
transactionIntent=new Intent(ChangellyService.INFO_TRANSACTION,null,this,ChangellyService.class);
res.amountFrom=amount;
transactionIntent.putExtra(OFFER,res);
}
LocalBroadcastManager.getInstance(this).sendBroadcast(transactionIntent);
break;
}
}
}

Fixed version (ground truth):
@Override protected void onHandleIntent(@Nullable Intent intent){
  Log.i(LOG_TAG,"String_Node_Str");
  if (intent != null && intent.getAction() != null) {
    String from, to, destAddress;
    double amount;
switch (intent.getAction()) {
case ACTION_GET_CURRENCIES:
      if (currencies == null) {
        loadCurrencies();
      }
    if (currencies == null || currencies.size() == 0) {
      Intent errorIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
      LocalBroadcastManager.getInstance(this).sendBroadcast(errorIntent);
      break;
    }
  Intent currenciesIntent=new Intent(ChangellyService.INFO_CURRENCIES,null,this,ChangellyService.class);
currenciesIntent.putExtra(CURRENCIES,currencies.toArray());
currenciesIntent.putStringArrayListExtra(CURRENCIES,new ArrayList<>(currencies));
LocalBroadcastManager.getInstance(this).sendBroadcast(currenciesIntent);
break;
case ACTION_GET_MIN_EXCHANGE:
from=intent.getStringExtra(FROM);
to=intent.getStringExtra(TO);
double min=getMinAmount(from,to);
if (min == -1) {
Intent errorIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
LocalBroadcastManager.getInstance(this).sendBroadcast(errorIntent);
return;
}
Intent minAmountIntent=new Intent(ChangellyService.INFO_MIN_AMOUNT,null,this,ChangellyService.class);
minAmountIntent.putExtra(FROM,from);
minAmountIntent.putExtra(TO,to);
minAmountIntent.putExtra(AMOUNT,min);
LocalBroadcastManager.getInstance(this).sendBroadcast(minAmountIntent);
break;
case ACTION_GET_EXCHANGE_AMOUNT:
from=intent.getStringExtra(FROM);
to=intent.getStringExtra(TO);
amount=intent.getDoubleExtra(AMOUNT,0);
double offer=getExchangeAmount(from,to,amount);
if (offer == -1) {
Intent errorIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
LocalBroadcastManager.getInstance(this).sendBroadcast(errorIntent);
return;
}
Intent exchangeAmountIntent=new Intent(ChangellyService.INFO_EXCH_AMOUNT,null,this,ChangellyService.class);
exchangeAmountIntent.putExtra(FROM,from);
exchangeAmountIntent.putExtra(TO,to);
exchangeAmountIntent.putExtra(FROM_AMOUNT,amount);
exchangeAmountIntent.putExtra(AMOUNT,offer);
LocalBroadcastManager.getInstance(this).sendBroadcast(exchangeAmountIntent);
break;
case ACTION_CREATE_TRANSACTION:
from=intent.getStringExtra(FROM);
to=intent.getStringExtra(TO);
amount=intent.getDoubleExtra(AMOUNT,0);
destAddress=intent.getStringExtra(DESTADDRESS);
ChangellyTransactionOffer res=createTransaction(from,to,amount,destAddress);
Intent transactionIntent;
if (res == null) {
transactionIntent=new Intent(ChangellyService.INFO_ERROR,null,this,ChangellyService.class);
}
 else {
transactionIntent=new Intent(ChangellyService.INFO_TRANSACTION,null,this,ChangellyService.class);
res.amountFrom=amount;
transactionIntent.putExtra(OFFER,res);
}
LocalBroadcastManager.getInstance(this).sendBroadcast(transactionIntent);
break;
}
}
}