Buggy code:
public class DesktopTxProvider implements IDesktopTxProvider { private static final String queryTxHashOfHDAccount = "<seq2seq4repair_space>select<seq2seq4repair_space>distinct<seq2seq4repair_space>txs.tx_hash<seq2seq4repair_space>from<seq2seq4repair_space>addresses_txs<seq2seq4repair_space>txs<seq2seq4repair_space>,desktop_hdm_account_addresses<seq2seq4repair_space>hd<seq2seq4repair_space>where<seq2seq4repair_space>txs.address=hd.address" ; private static final String inQueryTxHashOfDesktopHDMKeychain = ( "<seq2seq4repair_space>(" + ( DesktopTxProvider . queryTxHashOfHDAccount ) ) + ")" ; private static DesktopTxProvider enDesktopTxProvider = new DesktopTxProvider ( ApplicationInstanceManager . txDBHelper ) ; private TxDBHelper mDb ; public static DesktopTxProvider getInstance ( ) { } private DesktopTxProvider ( TxDBHelper db ) { } private static final String insert_hdm_address_sql = "insert<seq2seq4repair_space>into<seq2seq4repair_space>desktop_hdm_account_addresses<seq2seq4repair_space>" + ( "(path_type,address_index,is_issued,address,pub_key_1,pub_key_2,pub_key_3,is_synced)" + "<seq2seq4repair_space>values<seq2seq4repair_space>(?,?,?,?,?,?,?,?)<seq2seq4repair_space>" ) ; @ Override public void addAddress ( List < DesktopHDMAddress > addressList ) { } @ Override public int maxHDMAddressPubIndex ( ) { } @ Override public String externalAddress ( ) { } @ Override public boolean hasAddress ( ) { } @ Override public long getHDAccountConfirmedBanlance ( int hdSeedId ) { } @ Override public HashSet < String > getBelongAccountAddresses ( List < String > addressList ) { } @ Override public void updateIssuedIndex ( AbstractHD . PathType pathType , int index ) { } @ Override public int issuedIndex ( AbstractHD . PathType pathType ) { } @ Override public int allGeneratedAddressCount ( AbstractHD . PathType pathType ) { } @ Override public List < Tx > getHDAccountUnconfirmedTx ( ) { } @ Override public List < HDMAddress . Pubs > getPubs ( AbstractHD . PathType pathType ) { } @ Override public int getUnspendOutCountByHDAccountWithPath ( int hdAccountId , AbstractHD . PathType pathType ) { } @ Override public List < Out > getUnspendOutByHDAccountWithPath ( int hdAccountId , AbstractHD . PathType pathType ) { } @ Override public DesktopHDMAddress addressForPath ( DesktopHDMKeychain keychain , AbstractHD . PathType type , int index ) { } @ Override public List < DesktopHDMAddress > getSigningAddressesForInputs ( DesktopHDMKeychain keychain , List < In > inList ) { } @ Override public List < DesktopHDMAddress > belongAccount ( DesktopHDMKeychain keychain , List < String > addresses ) { List < DesktopHDMAddress > desktopHDMAddresses = new ArrayList < DesktopHDMAddress > ( ) ; List < String > temp = new ArrayList < String > ( ) ; for ( String str : addresses ) { temp . add ( Utils . format ( "'%s'" , str ) ) ; } <START_BUG> String sql = ( "select<seq2seq4repair_space>address,pub,path_type,address_index,is_issued,is_synced<seq2seq4repair_space>from<seq2seq4repair_space>desktop_hdm_account_addresses<seq2seq4repair_space>where<seq2seq4repair_space>address<seq2seq4repair_space>in<seq2seq4repair_space>(" + ( Utils . joinString ( temp , "," ) ) ) + ")" ; <END_BUG> try { PreparedStatement statement = this . mDb . getPreparedStatement ( sql , null ) ; ResultSet cursor = statement . executeQuery ( ) ; while ( cursor . next ( ) ) { desktopHDMAddresses . add ( formatAddress ( keychain , cursor ) ) ; } cursor . close ( ) ; statement . close ( ) ; } catch ( SQLException e ) { e . printStackTrace ( ) ; } return desktopHDMAddresses ; } private DesktopHDMAddress formatAddress ( DesktopHDMKeychain keychain , ResultSet c ) throws SQLException { } }

Fix:
String sql = ( "select<seq2seq4repair_space>*<seq2seq4repair_space>from<seq2seq4repair_space>desktop_hdm_account_addresses<seq2seq4repair_space>where<seq2seq4repair_space>address<seq2seq4repair_space>in<seq2seq4repair_space>(" + ( Utils . joinString ( temp , "," ) ) ) + ")" ;