nus-yam/ex-repair huggingface dataset:
Buggy code:
public abstract class DateLayout extends Layout { public static final String NULL_DATE_FORMAT = "NULL" ; public static final String RELATIVE_TIME_DATE_FORMAT = "RELATIVE" ; public static final String DATE_FORMAT_OPTION = "DateFormat" ; public static final String TIMEZONE_OPTION = "TimeZone" ; protected FieldPosition pos = new FieldPosition ( 0 ) ; private String timeZoneID ; private String dateFormatOption ; protected DateFormat dateFormat ; protected Date date = new Date ( ) ; public void setDateFormat ( String dateFormat ) { } public String getDateFormat ( ) { } public void setTimeZone ( String timeZone ) { } public String getTimeZone ( ) { } public void activateOptions ( ) { } public void dateFormat ( StringBuffer buf , LoggingEvent event ) { if ( ( dateFormat ) != null ) { <START_BUG> date . setTime ( event . timeStamp ) ; <END_BUG> dateFormat . format ( date , buf , this . pos ) ; buf . append ( '<seq2seq4repair_space>' ) ; } } public void setDateFormat ( DateFormat dateFormat , TimeZone timeZone ) { } public void setDateFormat ( String dateFormatType , TimeZone timeZone ) { } }

Fix:
date . setTime ( event . getTimeStamp ( ) ) ;
Buggy code:
public class LehrpersonenWebviewParser extends Parser { final WebView wv ; final TextView label ; public LehrpersonenWebviewParser ( MainActivity a ) { } @ Override public void parseResult ( String result , Searcher s ) { wv . setVisibility ( GONE ) ; label . setVisibility ( GONE ) ; if ( s . results_found ) { wv . setVisibility ( VISIBLE ) ; label . setVisibility ( VISIBLE ) ; <START_BUG> wv . loadDataWithBaseURL ( s . searchUrl , result , "text//html;<seq2seq4repair_space>chartset=utf-8" , "utf-8" , null ) ; <END_BUG> } } }

Fix:
wv . loadData ( result , "text//html;<seq2seq4repair_space>charset=utf-8" , "utf-8" ) ;
Buggy code:
public class XMLInterceptorB { private static final Logger log = Logger . getLogger ( XMLInterceptorB . class ) ; MySession2RemoteB session2 ; public Object intercept ( InvocationContext ctx ) throws Exception { XMLInterceptorB . log . info ( "Calling<seq2seq4repair_space>XMLInterceptorB..." ) ; <START_BUG> session2 . doit ( ) ; <END_BUG> XMLInterceptorB . log . info ( "Calling<seq2seq4repair_space>XMLInterceptorB<seq2seq4repair_space>-<seq2seq4repair_space>after<seq2seq4repair_space>doit" ) ; return false ; } }

Fix:
session2 . doitSession ( ) ;
Buggy code:
public class MapFactoryBean extends AbstractFactoryBean { private Map sourceMap ; private Class targetMapClass ; public void setSourceMap ( Map sourceMap ) { } public void setTargetMapClass ( Class targetMapClass ) { } @ Override public Class getObjectType ( ) { } @ Override protected Object createInstance ( ) { if ( ( this . sourceMap ) == null ) { throw new IllegalArgumentException ( "'sourceMap'<seq2seq4repair_space>is<seq2seq4repair_space>required" ) ; } Map result = null ; if ( ( this . targetMapClass ) != null ) { result = ( ( Map ) ( BeanUtils . instantiateClass ( this . targetMapClass ) ) ) ; } else { result = new LinkedHashMap ( this . sourceMap . size ( ) ) ; } Class keyType = null ; Class valueType = null ; <START_BUG> if ( ( ( this . targetMapClass ) != null ) && ( JdkVersion . isAtLeastJava15 ( ) ) ) { <END_BUG> keyType = GenericCollectionTypeResolver . getMapKeyType ( this . targetMapClass ) ; valueType = GenericCollectionTypeResolver . getMapValueType ( this . targetMapClass ) ; } if ( ( keyType != null ) || ( valueType != null ) ) { TypeConverter converter = getBeanTypeConverter ( ) ; for ( Iterator it = this . sourceMap . entrySet ( ) . iterator ( ) ; it . hasNext ( ) ; ) { Map . Entry entry = ( ( Map . Entry ) ( it . next ( ) ) ) ; Object convertedKey = converter . convertIfNecessary ( entry . getKey ( ) , keyType ) ; Object convertedValue = converter . convertIfNecessary ( entry . getValue ( ) , valueType ) ; result . put ( convertedKey , convertedValue ) ; } } else { result . putAll ( this . sourceMap ) ; } return result ; } }

Fix:
if ( ( this . targetMapClass ) != null ) {
Buggy code:
class HtmlParserHTMLParser extends HTMLParser { private static final Logger log = LoggingManager . getLoggerForClass ( ) ; protected HtmlParserHTMLParser ( ) { } @ Override protected boolean isReusable ( ) { } @ Override public Iterator < URL > getEmbeddedResourceURLs ( byte [ ] html , URL baseUrl , URLCollection urls , String encoding ) throws HTMLParseException { } private static class URLPointer { private URLPointer ( URL newUrl ) { } private URL url ; } private void parseNodes ( final NodeIterator e , final HtmlParserHTMLParser . URLPointer baseUrl , final URLCollection urls ) throws HTMLParseException , ParserException { while ( e . hasMoreNodes ( ) ) { Node node = e . nextNode ( ) ; if ( ! ( node instanceof Tag ) ) { continue ; } Tag tag = ( ( Tag ) ( node ) ) ; String tagname = tag . getTagName ( ) ; String binUrlStr = null ; if ( tag instanceof BodyTag ) { binUrlStr = tag . getAttribute ( ATT_BACKGROUND ) ; } else if ( tag instanceof BaseHrefTag ) { BaseHrefTag baseHref = ( ( BaseHrefTag ) ( tag ) ) ; String baseref = baseHref . getBaseUrl ( ) ; try { if ( ! ( baseref . equals ( "" ) ) ) { <START_BUG> baseUrl . url = ConversionUtils . makeRelativeURL ( baseUrl . url , baseHref . getBaseUrl ( ) ) ; <END_BUG> } } catch ( MalformedURLException e1 ) { throw new HTMLParseException ( e1 ) ; } } else if ( tag instanceof ImageTag ) { ImageTag image = ( ( ImageTag ) ( tag ) ) ; binUrlStr = image . getImageURL ( ) ; } else if ( tag instanceof AppletTag ) { AppletTag applet = ( ( AppletTag ) ( tag ) ) ; binUrlStr = applet . getAppletClass ( ) ; } else if ( tag instanceof ObjectTag ) { ObjectTag applet = ( ( ObjectTag ) ( tag ) ) ; String data = applet . getAttribute ( "codebase" ) ; if ( ! ( StringUtils . isEmpty ( data ) ) ) { binUrlStr = data ; } data = applet . getAttribute ( "data" ) ; if ( ! ( StringUtils . isEmpty ( data ) ) ) { binUrlStr = data ; } } else if ( tag instanceof InputTag ) { if ( ATT_IS_IMAGE . equalsIgnoreCase ( tag . getAttribute ( ATT_TYPE ) ) ) { binUrlStr = tag . getAttribute ( ATT_SRC ) ; } } else if ( tag instanceof ScriptTag ) { binUrlStr = tag . getAttribute ( ATT_SRC ) ; } else if ( ( tag instanceof FrameTag ) || ( tagname . equalsIgnoreCase ( TAG_IFRAME ) ) ) { binUrlStr = tag . getAttribute ( ATT_SRC ) ; } else if ( ( tagname . equalsIgnoreCase ( TAG_EMBED ) ) || ( tagname . equalsIgnoreCase ( TAG_BGSOUND ) ) ) { binUrlStr = tag . getAttribute ( ATT_SRC ) ; } else if ( tagname . equalsIgnoreCase ( TAG_LINK ) ) { if ( STYLESHEET . equalsIgnoreCase ( tag . getAttribute ( ATT_REL ) ) ) { binUrlStr = tag . getAttribute ( ATT_HREF ) ; } } else { binUrlStr = tag . getAttribute ( ATT_BACKGROUND ) ; } if ( binUrlStr != null ) { urls . addURL ( binUrlStr , baseUrl . url ) ; } String styleTagStr = tag . getAttribute ( ATT_STYLE ) ; if ( styleTagStr != null ) { HtmlParsingUtils . extractStyleURLs ( baseUrl . url , urls , styleTagStr ) ; } if ( tag instanceof CompositeTag ) { CompositeTag composite = ( ( CompositeTag ) ( tag ) ) ; parseNodes ( composite . elements ( ) , baseUrl , urls ) ; } } } }

Fix:
baseUrl . url = ConversionUtils . makeRelativeURL ( baseUrl . url , baseref ) ;
Buggy code:
public class ViewFolderInfoPanelAction extends AbstractSelectableAction { public ViewFolderInfoPanelAction ( FrameMediator frameMediator ) { } public void actionPerformed ( ActionEvent evt ) { <START_BUG> ( ( org . columba . mail . gui . view . AbstractMailView ) ( frameMediator . getBaseView ( ) ) ) . showFolderInfoPanel ( ) ; <END_BUG> } }

Fix:
( ( org . columba . mail . gui . view . AbstractMailView ) ( frameMediator . getView ( ) ) ) . showFolderInfoPanel ( ) ;
Buggy code:
public class LocalVariablePattern extends VariablePattern { LocalVariable localVariable ; public LocalVariablePattern ( LocalVariable localVariable , int limitTo , int matchRule ) { } public void findIndexMatches ( Index index , IndexQueryRequestor requestor , SearchParticipant participant , IJavaSearchScope scope , IProgressMonitor progressMonitor ) { IPackageFragmentRoot root = ( ( IPackageFragmentRoot ) ( this . localVariable . getAncestor ( IJavaElement . PACKAGE_FRAGMENT_ROOT ) ) ) ; String documentPath ; String relativePath ; if ( root . isArchive ( ) ) { IType type = ( ( IType ) ( this . localVariable . getAncestor ( IJavaElement . TYPE ) ) ) ; <START_BUG> relativePath = ( type . getFullyQualifiedName ( '//' ) . replace ( '.' , '//' ) ) + ( SuffixConstants . SUFFIX_STRING_class ) ; <END_BUG> documentPath = ( ( root . getPath ( ) ) + ( IJavaSearchScope . JAR_FILE_ENTRY_SEPARATOR ) ) + relativePath ; } else { IPath path = this . localVariable . getPath ( ) ; documentPath = path . toString ( ) ; relativePath = Util . relativePath ( path , 1 ) ; } if ( scope instanceof JavaSearchScope ) { JavaSearchScope javaSearchScope = ( ( JavaSearchScope ) ( scope ) ) ; AccessRuleSet access = javaSearchScope . getAccessRuleSet ( relativePath , index . containerPath ) ; if ( access != ( JavaSearchScope . NOT_ENCLOSED ) ) { if ( ! ( requestor . acceptIndexMatch ( documentPath , this , participant , access ) ) ) throw new OperationCanceledException ( ) ; } } else if ( scope . encloses ( documentPath ) ) { if ( ! ( requestor . acceptIndexMatch ( documentPath , this , participant , null ) ) ) throw new OperationCanceledException ( ) ; } } protected StringBuffer print ( StringBuffer output ) { } }

Fix:
relativePath = ( type . getFullyQualifiedName ( '$' ) . replace ( '.' , '//' ) ) + ( SuffixConstants . SUFFIX_STRING_class ) ;
Buggy code:
public class FastDateFormatTest { @ Test public void test_getInstance ( ) { } @ Test public void test_getInstance_String ( ) { } @ Test public void test_getInstance_String_TimeZone ( ) { } @ Test public void test_getInstance_String_Locale ( ) { } @ Test public void test_changeDefault_Locale_DateInstance ( ) { } @ Test public void test_changeDefault_Locale_DateTimeInstance ( ) { } @ Test public void test_getInstance_String_TimeZone_Locale ( ) { } @ Test public void testCheckDefaults ( ) { } @ Test public void testCheckDifferingStyles ( ) { } @ Test public void testDateDefaults ( ) { } @ Test public void testTimeDefaults ( ) { } @ Test public void testTimeDateDefaults ( ) { } @ Test public void testParseSync ( ) throws InterruptedException { final String pattern = "yyyy-MM-dd'T'HH:mm:ss.SSS<seq2seq4repair_space>Z" ; final FastDateFormat formatter = FastDateFormat . getInstance ( pattern ) ; long sdfTime = measureTime ( formatter , new SimpleDateFormat ( pattern ) { private static final long serialVersionUID = 1L ; @ Override public Object parseObject ( String formattedDate ) throws ParseException { synchronized ( this ) { return super . parse ( formattedDate ) ; } } } ) ; long fdfTime = measureTime ( formatter , FastDateFormat . getInstance ( pattern ) ) ; <START_BUG> String times = ( ( "FastDateParserTest:<seq2seq4repair_space>FastDateParser:" + fdfTime ) + "<seq2seq4repair_space>SimpleDateFormat:" ) + sdfTime ; <END_BUG> System . out . println ( times ) ; } private static final int NTHREADS = 10 ; private static final int NROUNDS = 10000 ; private long measureTime ( final Format formatter , final Format parser ) throws InterruptedException { } }

Fix:
String times = ( ( ">>FastDateFormatTest:<seq2seq4repair_space>FastDateParser:" + fdfTime ) + "<seq2seq4repair_space>SimpleDateFormat:" ) + sdfTime ;
Buggy code:
@ SuppressWarnings ( "serial" ) public class PaintLabel extends MLabel { private int x = 0 ; private int y = 0 ; private PaintListener paintListener ; private MPanel jpnl_toMove ; public PaintLabel ( final MPanel _jpnl_toMove ) { } public final void setPaintListener ( final PaintListener _pl ) { } @ Override public final synchronized void setLocation ( final int _x , final int _y ) { } public final void setLoc ( final int _x , final int _y ) { <START_BUG> super . setLocation ( _x , _y ) ; <END_BUG> } @ Override public final void setLocation ( final Point _p ) { } @ Override public final void setBounds ( final int _x , final int _y , final int _widht , final int _height ) { } @ Deprecated @ Override public final int getX ( ) { } @ Deprecated @ Override public final int getY ( ) { } @ Override public final Point getLocation ( ) { } @ Override public final Rectangle getBounds ( ) { } }

Fix:
super . setBounds ( _x , _y , getWidth ( ) , getHeight ( ) ) ;
Buggy code:
public class ConnectionMy extends AsyncTask < String , String , String > { Context context ; ProgressDialog dialog ; ConnectionMy ( Context context , ProgressDialog dialog ) { } public String Search ( int Categorie , float latiude , float longitude , int Radius ) throws IOException , ClientProtocolException { } public List < String > Parse ( ) { } @ Override protected String doInBackground ( String ... params ) { } @ Override protected void onPostExecute ( String responseStr ) { Entries e = Entries . getInstance ( ) ; JSONObject j ; JSONArray array ; dialog . cancel ( ) ; e . MyEntries . clear ( ) ; if ( responseStr . equals ( "" ) ) { CharSequence text = "Error<seq2seq4repair_space>connecting<seq2seq4repair_space>please<seq2seq4repair_space>try<seq2seq4repair_space>again<seq2seq4repair_space>later" ; Toast t = Toast . makeText ( context , text , LENGTH_LONG ) ; t . show ( ) ; return ; } try { responseStr = Html . fromHtml ( responseStr ) . toString ( ) ; array = new JSONArray ( responseStr ) ; for ( int n = 0 ; n < ( array . length ( ) ) ; n ++ ) { j = array . getJSONObject ( n ) ; <START_BUG> e . addMyEntry ( j . getInt ( "id" ) , j . getString ( "categorie" ) , j . getString ( "productName" ) , ( ( float ) ( j . getDouble ( "price" ) ) ) , j . getInt ( "quantity" ) , j . getString ( "contactDetails" ) , ( ( float ) ( j . getDouble ( "latitude" ) ) ) , ( ( float ) ( j . getDouble ( "longtitude" ) ) ) , j . getString ( "beginTime" ) , j . getString ( "endTime" ) , ( - 1 ) , j . getBoolean ( "active" ) , j . getBoolean ( "retry" ) ) ; <END_BUG> } Intent i = new Intent ( context , EntryActivity . class ) ; i . addFlags ( FLAG_ACTIVITY_NEW_TASK ) ; context . startActivity ( i ) ; return ; } catch ( JSONException e1 ) { e1 . printStackTrace ( ) ; CharSequence text = "Something<seq2seq4repair_space>somewhere<seq2seq4repair_space>went<seq2seq4repair_space>terribly<seq2seq4repair_space>wrong" ; Toast t = Toast . makeText ( context , text , LENGTH_LONG ) ; t . show ( ) ; return ; } } protected void onProgressUpdate ( ) { } }

Fix:
e . addMyEntry ( j . getInt ( "id" ) , j . getString ( "categorie" ) , j . getString ( "productName" ) , ( ( float ) ( j . getDouble ( "price" ) ) ) , j . getInt ( "quantity" ) , j . getString ( "contactDetails" ) , ( ( float ) ( j . getDouble ( "latitude" ) ) ) , ( ( float ) ( j . getDouble ( "longtitude" ) ) ) , j . getString ( "beginTime" ) , j . getString ( "endTime" ) , j . getInt ( "user_id" ) , j . getBoolean ( "active" ) , j . getBoolean ( "retry" ) ) ;
Buggy code:
public class SecureLinkIt extends Controller { <START_BUG> @ Before ( unless = { "register" , "loginWith" , "loginLinkIt" , "signup" } ) <END_BUG> static void checkAccess ( ) throws Throwable { if ( ! ( session . contains ( "username" ) ) ) { Login . index ( ( "GET" . equals ( method ) ? request . url : "//" ) ) ; } Check check = getActionAnnotation ( Check . class ) ; if ( check != null ) { SecureLinkIt . check ( check ) ; } check = getControllerInheritedAnnotation ( Check . class ) ; if ( check != null ) { SecureLinkIt . check ( check ) ; } } private static void check ( Check check ) throws Throwable { } }

Fix:
@ Before ( unless = { "Profile.register" , "Profile.save" , "loginWith" , "loginLinkIt" , "signup" } )
Buggy code:
public class PublicationDetailsFragment extends Fragment { PublicationDetailsFragment . SectionsPagerAdapter mSectionsPagerAdapter ; public static final String TAG = PublicationDetailsFragment . class . getSimpleName ( ) ; ViewPager mViewPager ; private static String id ; public static PublicationDetailsFragment newInstance ( String id ) { } @ Override public void onCreate ( Bundle savedInstanceState ) { } @ Override public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { View v = inflater . inflate ( title_strip , container , false ) ; mSectionsPagerAdapter = new PublicationDetailsFragment . SectionsPagerAdapter ( getChildFragmentManager ( ) ) ; mViewPager = ( ( ViewPager ) ( v . findViewById ( pager ) ) ) ; mViewPager . setAdapter ( mSectionsPagerAdapter ) ; return v ; } @ Override public void setUserVisibleHint ( boolean isVisibleToUser ) { } public class SectionsPagerAdapter extends FragmentPagerAdapter { public SectionsPagerAdapter ( FragmentManager fm ) { } @ Override public Fragment getItem ( int position ) { } @ Override public int getCount ( ) { } @ Override public CharSequence getPageTitle ( int position ) { } } public static class TabbedView extends Fragment { public static final String ARG_SECTION_NUMBER = "section_number" ; @ Override public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { final View rootView = inflater . inflate ( fragment_details , container , false ) ; int sectionNumber = getArguments ( ) . getInt ( PublicationDetailsFragment . TabbedView . ARG_SECTION_NUMBER ) ; LinearLayout detailView = ( ( LinearLayout ) ( rootView . findViewById ( detailView ) ) ) ; final RelativeLayout commentLayout = ( ( RelativeLayout ) ( rootView . findViewById ( commentLayout ) ) ) ; <START_BUG> final ListView commentView = ( ( ListView ) ( rootView . findViewById ( commmentView ) ) ) ; <END_BUG> detailView . setVisibility ( INVISIBLE ) ; commentLayout . setVisibility ( INVISIBLE ) ; switch ( sectionNumber ) { case 1 : commentLayout . setVisibility ( GONE ) ; detailView . setVisibility ( VISIBLE ) ; setText ( rootView ) ; break ; case 2 : detailView . setVisibility ( GONE ) ; commentLayout . setVisibility ( VISIBLE ) ; loadComments ( commentView ) ; break ; } return rootView ; } private void loadComments ( final ListView commentView ) { } private void setText ( final View rootView ) { } } }

Fix:
final ListView commentView = ( ( ListView ) ( rootView . findViewById ( commentView ) ) ) ;
Buggy code:
public abstract class CollectionUtil { public static < E , F > ArrayList < F > filterMap ( Collection < E > collection , IFunction < E , F > function ) { } public static Object [ ] copyArray ( Object [ ] array , int from , int to ) { } @ Nullable public static < T > T getLastElement ( List < T > list ) { } public static < T > void setLastElement ( List < T > list , T elem ) { } public static < T > void addLastElement ( List < T > list , T element ) { } public static < T > Iterable < T > reverse ( final List < T > list ) { return new Iterable < T > ( ) { public Iterator < T > iterator ( ) { <START_BUG> final ListIterator < T > listIterator = list . listIterator ( ) ; <END_BUG> return new Iterator < T > ( ) { public boolean hasNext ( ) { return listIterator . hasPrevious ( ) ; } public T next ( ) { return listIterator . previous ( ) ; } public void remove ( ) { listIterator . remove ( ) ; } } ; } } ; } public static < T > Set < T > asSet ( T [ ] values ) { } No newline ; at end ; of file ; }

Fix:
final ListIterator < T > listIterator = list . listIterator ( list . size ( ) ) ;
Buggy code:
public class update { Message query ; Message response ; Resolver res ; String server = null ; Name zone = Name . root ; long defaultTTL ; int defaultClass = DClass . IN ; PrintStream log = null ; void print ( Object o ) { } public update ( InputStream in ) throws IOException { } void sendUpdate ( ) throws IOException { } Record parseRR ( Tokenizer st , int classValue , long TTLValue ) throws IOException { } void doRequire ( Tokenizer st ) throws IOException { } void doProhibit ( Tokenizer st ) throws IOException { } void doAdd ( Tokenizer st ) throws IOException { } void doDelete ( Tokenizer st ) throws IOException { } void doGlue ( Tokenizer st ) throws IOException { } void doQuery ( Tokenizer st ) throws IOException { } void doFile ( Tokenizer st , List inputs , List istreams ) throws IOException { } void doLog ( Tokenizer st ) throws IOException { } boolean doAssert ( Tokenizer st ) throws IOException { String field = st . getString ( ) ; String expected = st . getString ( ) ; String value = null ; boolean flag = true ; int section ; if ( ( response ) == null ) { print ( "No<seq2seq4repair_space>response<seq2seq4repair_space>has<seq2seq4repair_space>been<seq2seq4repair_space>received" ) ; return true ; } if ( field . equalsIgnoreCase ( "rcode" ) ) { <START_BUG> short rcode = response . getHeader ( ) . getRcode ( ) ; <END_BUG> if ( rcode != ( Rcode . value ( expected ) ) ) { value = Rcode . string ( rcode ) ; flag = false ; } } else if ( field . equalsIgnoreCase ( "serial" ) ) { Record [ ] answers = response . getSectionArray ( ANSWER ) ; if ( ( ( answers . length ) < 1 ) || ( ! ( ( answers [ 0 ] ) instanceof SOARecord ) ) ) print ( "Invalid<seq2seq4repair_space>response<seq2seq4repair_space>(no<seq2seq4repair_space>SOA)" ) ; else { SOARecord soa = ( ( SOARecord ) ( answers [ 0 ] ) ) ; long serial = soa . getSerial ( ) ; if ( serial != ( Long . parseLong ( expected ) ) ) { value = Long . toString ( serial ) ; flag = false ; } } } else if ( field . equalsIgnoreCase ( "tsig" ) ) { if ( response . isSigned ( ) ) { if ( response . isVerified ( ) ) value = "ok" ; else value = "failed" ; } else value = "unsigned" ; if ( ! ( value . equalsIgnoreCase ( expected ) ) ) flag = false ; } else if ( ( section = Section . value ( field ) ) >= 0 ) { int count = response . getHeader ( ) . getCount ( section ) ; if ( count != ( Integer . parseInt ( expected ) ) ) { value = new Integer ( count ) . toString ( ) ; flag = false ; } } else print ( ( "Invalid<seq2seq4repair_space>assertion<seq2seq4repair_space>keyword:<seq2seq4repair_space>" + field ) ) ; if ( flag == false ) { print ( ( ( ( ( ( "Expected<seq2seq4repair_space>" + field ) + "<seq2seq4repair_space>" ) + expected ) + ",<seq2seq4repair_space>received<seq2seq4repair_space>" ) + value ) ) ; while ( true ) { Tokenizer . Token token = st . get ( ) ; if ( ! ( token . isString ( ) ) ) break ; print ( token . value ) ; } st . unget ( ) ; } return flag ; } static void help ( String topic ) { } public static void main ( String [ ] args ) throws IOException { } }

Fix:
int rcode = response . getHeader ( ) . getRcode ( ) ;
Buggy code:
public class TestTypedResults extends SingleEMFTestCase { private static final int N_ORDERS = 15 ; private static final int N_ITEMS_PER_ORDER = 3 ; private static final String [ ] ORDER_DATES = new String [ ] { "3//12//2008<seq2seq4repair_space>1:00<seq2seq4repair_space>PM" , "10//01//2008<seq2seq4repair_space>1:51<seq2seq4repair_space>AM" , "12//12//2008<seq2seq4repair_space>10:01<seq2seq4repair_space>AM" , "5//21//2009<seq2seq4repair_space>3:23<seq2seq4repair_space>PM" } ; DateFormat df = DateFormat . getDateInstance ( DateFormat . SHORT , Locale . US ) ; public void setUp ( ) throws Exception { <START_BUG> setUp ( CLEAR_TABLES , Order . class , Item . class , Shop . class , Producer . class , "openjpa.DynamicEnhancerAgent" , "false" ) ; <END_BUG> populate ( ) ; } public void populate ( ) throws ParseException { } public void tearDown ( ) throws Exception { } public void testTypedJPQLQuery ( ) { } public void testDateQuery ( ) throws Exception { } public void testMultiSelect ( ) throws Exception { } }

Fix:
setUp ( CLEAR_TABLES , Order . class , Item . class , Shop . class , Producer . class , "openjpa.DynamicEnhancementAgent" , "false" ) ;
Buggy code:
@ SuppressWarnings ( "restriction" ) public class JAXWSSelectionTransformer implements Transformer { public Object transform ( Object value ) { if ( value instanceof IStructuredSelection ) { IStructuredSelection structuredSelection = ( ( IStructuredSelection ) ( value ) ) ; Object selection = structuredSelection . getFirstElement ( ) ; if ( selection instanceof IFile ) { IFile file = ( ( IFile ) ( selection ) ) ; String fullyQualifiedJavaName = this . getFullyQualifiedJavaName ( file ) ; return new StructuredSelection ( fullyQualifiedJavaName ) ; } else if ( selection instanceof ICompilationUnit ) { IResource resource = ( ( ICompilationUnit ) ( selection ) ) . getResource ( ) ; if ( resource instanceof IFile ) { IFile file = ( ( IFile ) ( resource ) ) ; String fullyQualifiedJavaName = this . getFullyQualifiedJavaName ( file ) ; return new StructuredSelection ( fullyQualifiedJavaName ) ; } } if ( selection instanceof String ) { return structuredSelection ; } } <START_BUG> return StructuredSelection . EMPTY ; <END_BUG> } private String getFullyQualifiedJavaName ( IFile resource ) { } }

Fix:
return value ;
Buggy code:
public class TextTransfer extends ByteArrayTransfer { private static TextTransfer _instance = new TextTransfer ( ) ; private static final String CF_UNICODETEXT = "CF_UNICODETEXT" ; private static final String CF_TEXT = "CF_TEXT" ; private static final int CF_UNICODETEXTID = COM . CF_UNICODETEXT ; private static final int CF_TEXTID = COM . CF_TEXT ; private TextTransfer ( ) { } public static TextTransfer getInstance ( ) { } public void javaToNative ( Object object , TransferData transferData ) { } public Object nativeToJava ( TransferData transferData ) { if ( ( ! ( isSupportedType ( transferData ) ) ) || ( ( transferData . pIDataObject ) == 0 ) ) return null ; IDataObject data = new IDataObject ( transferData . pIDataObject ) ; data . AddRef ( ) ; FORMATETC formatetc = transferData . formatetc ; STGMEDIUM stgmedium = new STGMEDIUM ( ) ; stgmedium . tymed = COM . TYMED_HGLOBAL ; <START_BUG> transferData . result = data . GetData ( formatetc , stgmedium ) ; <END_BUG> data . Release ( ) ; if ( ( transferData . result ) != ( COM . S_OK ) ) return null ; int hMem = stgmedium . unionField ; try { switch ( transferData . type ) { case TextTransfer . CF_UNICODETEXTID : { int size = ( ( OS . GlobalSize ( hMem ) ) // 2 ) * 2 ; if ( size == 0 ) return null ; char [ ] chars = new char [ size // 2 ] ; int ptr = OS . GlobalLock ( hMem ) ; if ( ptr == 0 ) return null ; try { OS . MoveMemory ( chars , ptr , size ) ; int length = chars . length ; for ( int i = 0 ; i < ( chars . length ) ; i ++ ) { if ( ( chars [ i ] ) == '' ) { length = i ; break ; } } return new String ( chars , 0 , length ) ; } finally { OS . GlobalUnlock ( hMem ) ; } } case TextTransfer . CF_TEXTID : { int lpMultiByteStr = OS . GlobalLock ( hMem ) ; if ( lpMultiByteStr == 0 ) return null ; try { int codePage = OS . GetACP ( ) ; int cchWideChar = OS . MultiByteToWideChar ( codePage , MB_PRECOMPOSED , lpMultiByteStr , ( - 1 ) , null , 0 ) ; if ( cchWideChar == 0 ) return null ; char [ ] lpWideCharStr = new char [ cchWideChar - 1 ] ; OS . MultiByteToWideChar ( codePage , MB_PRECOMPOSED , lpMultiByteStr , ( - 1 ) , lpWideCharStr , lpWideCharStr . length ) ; return new String ( lpWideCharStr ) ; } finally { OS . GlobalUnlock ( hMem ) ; } } } } finally { OS . GlobalFree ( hMem ) ; } return null ; } protected int [ ] getTypeIds ( ) { } protected String [ ] getTypeNames ( ) { } boolean checkText ( Object object ) { } protected boolean validate ( Object object ) { } }

Fix:
transferData . result = getData ( data , formatetc , stgmedium ) ;
Buggy code:
public class ColumnFamilyOutputFormatTest extends EmbeddedServer { static final String KEYSPACE = "ColumnFamilyOutputFormatTestKeyspace" ; static final String COLUMN_FAMILY = "outputColumnFamily" ; private static final String INPUT_FOLDER = "columnfamily.outputtest" ; private static final String INPUT_FILE = "rows.txt" ; private static final int NUMBER_OF_ROWS = 3 ; private static final int NUMBER_OF_COLUMNS = 4 ; List < Integer > rowKeys ; List < Integer > columnValues ; private static FileSystem fs ; private Client thriftClient ; @ Before public void setup ( ) throws Exception { } @ After public void tearDown ( ) throws Exception { } private void deleteRows ( ) throws InvalidRequestException , TException { } private void deleteInputFile ( ) throws IOException { } private void setupCassandra ( ) throws InvalidRequestException , TException { TSocket socket = new TSocket ( DatabaseDescriptor . getListenAddress ( ) . getHostName ( ) , DatabaseDescriptor . getRpcPort ( ) ) ; TTransport transport = new org . apache . thrift . transport . TFramedTransport ( socket ) ; <START_BUG> TBinaryProtocol binaryProtocol = new TBinaryProtocol ( transport , false , false ) ; <END_BUG> Cassandra . Client cassandraClient = new Cassandra . Client ( binaryProtocol ) ; transport . open ( ) ; thriftClient = cassandraClient ; Set < String > keyspaces = thriftClient . describe_keyspaces ( ) ; if ( ! ( keyspaces . contains ( ColumnFamilyOutputFormatTest . KEYSPACE ) ) ) { List < CfDef > cfDefs = new ArrayList < CfDef > ( ) ; thriftClient . system_add_keyspace ( new org . apache . cassandra . thrift . KsDef ( ColumnFamilyOutputFormatTest . KEYSPACE , "org.apache.cassandra.locator.RackUnawareStrategy" , 1 , cfDefs ) ) ; } thriftClient . set_keyspace ( ColumnFamilyOutputFormatTest . KEYSPACE ) ; CfDef cfDef = new CfDef ( ColumnFamilyOutputFormatTest . KEYSPACE , ColumnFamilyOutputFormatTest . COLUMN_FAMILY ) ; try { thriftClient . system_add_column_family ( cfDef ) ; } catch ( InvalidRequestException e ) { throw new RuntimeException ( e ) ; } } private void defineRows ( ) { } Path inputdir ; private void createInputFile ( ) throws IOException { } @ Test public void testCopyCF ( ) throws Exception { } public void verifyOutput ( ) throws Exception { } private void verifyKeyValues ( Integer key , List < Integer > columnValues ) throws Exception { } }

Fix:
TBinaryProtocol binaryProtocol = new TBinaryProtocol ( transport ) ;
Buggy code:
public class HttpClientStarter extends Starter { private static final String USERAGENT = "JRDS<seq2seq4repair_space>HTTP<seq2seq4repair_space>agent" ; private CloseableHttpClient client = null ; private int maxConnect = 0 ; private int timeout = 0 ; @ Override public void configure ( PropertiesManager pm ) { } @ Override public boolean start ( ) { } private final SSLConnectionSocketFactory getSSLSocketFactory ( ) { SSLStarter sslstarter = getLevel ( ) . find ( SSLStarter . class ) ; SSLContext sc = sslstarter . getContext ( ) ; try { sc = SSLContexts . custom ( ) . loadTrustMaterial ( new TrustStrategy ( ) { @ Override public boolean isTrusted ( X509Certificate [ ] chain , String authType ) throws CertificateException { <START_BUG> log ( Level . TRACE , "trying<seq2seq4repair_space>to<seq2seq4repair_space>check<seq2seq4repair_space>certificates<seq2seq4repair_space>chain<seq2seq4repair_space>%s<seq2seq4repair_space>with<seq2seq4repair_space>authentication<seq2seq4repair_space>methode<seq2seq4repair_space>%s" , chain , authType ) ; <END_BUG> return true ; } } ) . build ( ) ; } catch ( KeyManagementException | NoSuchAlgorithmException | KeyStoreException e ) { throw new RuntimeException ( "failed<seq2seq4repair_space>to<seq2seq4repair_space>set<seq2seq4repair_space>a<seq2seq4repair_space>SSL<seq2seq4repair_space>context" , e ) ; } return new SSLConnectionSocketFactory ( sc , NoopHostnameVerifier . INSTANCE ) ; } @ Override public void stop ( ) { } public HttpClient getHttpClient ( ) { } @ Override public boolean isStarted ( ) { } }

Fix:
log ( Level . TRACE , "trying<seq2seq4repair_space>to<seq2seq4repair_space>check<seq2seq4repair_space>certificates<seq2seq4repair_space>chain<seq2seq4repair_space>%s<seq2seq4repair_space>with<seq2seq4repair_space>authentication<seq2seq4repair_space>method<seq2seq4repair_space>%s" , chain , authType ) ;
Buggy code:
public class BoostingTermQuery extends SpanTermQuery { public BoostingTermQuery ( Term term ) { } protected Weight createWeight ( Searcher searcher ) throws IOException { } protected class BoostingTermWeight extends SpanWeight implements Weight { public BoostingTermWeight ( BoostingTermQuery query , Searcher searcher ) throws IOException { } public Scorer scorer ( IndexReader reader ) throws IOException { } class BoostingSpanScorer extends SpanScorer { byte [ ] payload = new byte [ 256 ] ; private TermPositions positions ; protected float payloadScore ; private int payloadsSeen ; public BoostingSpanScorer ( TermSpans spans , Weight weight , Similarity similarity , byte [ ] norms ) throws IOException { } protected boolean setFreqCurrentDoc ( ) throws IOException { } protected void processPayload ( Similarity similarity ) throws IOException { } public float score ( ) throws IOException { } public Explanation explain ( final int doc ) throws IOException { Explanation result = new Explanation ( ) ; Explanation nonPayloadExpl = super . explain ( doc ) ; result . addDetail ( nonPayloadExpl ) ; Explanation payloadBoost = new Explanation ( ) ; result . addDetail ( payloadBoost ) ; <START_BUG> float avgPayloadScore = ( payloadScore ) // ( payloadsSeen ) ; <END_BUG> payloadBoost . setValue ( avgPayloadScore ) ; payloadBoost . setDescription ( "scorePayload(...)" ) ; result . setValue ( ( ( nonPayloadExpl . getValue ( ) ) * avgPayloadScore ) ) ; result . setDescription ( "btq,<seq2seq4repair_space>product<seq2seq4repair_space>of:" ) ; return result ; } } } public boolean equals ( Object o ) { } }

Fix:
float avgPayloadScore = ( ( payloadsSeen ) > 0 ) ? ( payloadScore ) // ( payloadsSeen ) : 1 ;
Buggy code:
public class ComponentStringResourceLoaderTest extends StringResourceLoaderTestBase { @ Override protected IStringResourceLoader createLoader ( ) { } @ Override public void testLoaderUnknownResources ( ) { } public void testNullComponent ( ) { <START_BUG> Assert . assertNull ( "Null<seq2seq4repair_space>component<seq2seq4repair_space>should<seq2seq4repair_space>skip<seq2seq4repair_space>resource<seq2seq4repair_space>load" , loader . loadStringResource ( null , "test.string" , Locale . getDefault ( ) , null , null ) ) ; <END_BUG> } public void testMultiLevelEmbeddedComponentLoadFromComponent ( ) { } public void testLoadDirectFromPage ( ) { } public void testSearchClassHierarchyFromPage ( ) { } }

Fix:
Assert . assertNull ( "Null<seq2seq4repair_space>component<seq2seq4repair_space>should<seq2seq4repair_space>skip<seq2seq4repair_space>resource<seq2seq4repair_space>load" , loader . loadStringResource ( ( ( Component ) ( null ) ) , "test.string" , Locale . getDefault ( ) , null , null ) ) ;
Buggy code:
public class PersistenceUnitParseProcessor implements DeploymentUnitProcessor { private static final String WEB_PERSISTENCE_XML = "WEB-INF//classes//META-INF//persistence.xml" ; private static final String META_INF_PERSISTENCE_XML = "META-INF//persistence.xml" ; private static final String JAR_FILE_EXTENSION = ".jar" ; private static final String LIB_FOLDER = "lib" ; @ Override public void deploy ( DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { } @ Override public void undeploy ( DeploymentUnit context ) { } private void handleJarDeployment ( DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { } private void handleWarDeployment ( DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { } private void handleEarDeployment ( DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { } private void parse ( final VirtualFile persistence_xml , final List < PersistenceUnitMetadataHolder > listPUHolders , final DeploymentUnit deploymentUnit ) throws DeploymentUnitProcessingException { } private void postParseSteps ( final VirtualFile persistence_xml , final PersistenceUnitMetadataHolder puHolder , final DeploymentUnit deploymentUnit ) { } private static URL getRelativeURL ( VirtualFile persistence_xml , String jar , boolean convertVFS ) { } private URL getPersistenceUnitURL ( VirtualFile persistence_xml , boolean convertVFS ) { try { VirtualFile metaData = persistence_xml ; <START_BUG> return convertVFS ? metaData . getParent ( ) . getParent ( ) . getPhysicalFile ( ) . toURI ( ) . toURL ( ) : metaData . getParent ( ) . getParent ( ) . toURL ( ) ; <END_BUG> } catch ( Exception e ) { throw new RuntimeException ( e ) ; } } private PersistenceUnitMetadataHolder normalize ( List < PersistenceUnitMetadataHolder > listPUHolders ) { } static boolean isEarDeployment ( final DeploymentUnit context ) { } static boolean isWarDeployment ( final DeploymentUnit context ) { } private static String getScopedDeploymentUnitPath ( DeploymentUnit deploymentUnit ) { } public static String createBeanName ( DeploymentUnit deploymentUnit , String persistenceUnitName ) { } private void markDU ( PersistenceUnitMetadataHolder holder , DeploymentUnit deploymentUnit ) { } private void incrementPersistenceUnitCount ( DeploymentUnit topDeploymentUnit , int persistenceUnitCount ) { } private void addApplicationDependenciesOnProvider ( DeploymentUnit topDeploymentUnit , PersistenceUnitMetadataHolder holder ) { } private PersistenceUnitsInApplication getPersistenceUnitsInApplication ( DeploymentUnit topDeploymentUnit ) { } }

Fix:
return convertVFS ? metaData . getPhysicalFile ( ) . getParentFile ( ) . getParentFile ( ) . toURI ( ) . toURL ( ) : metaData . getParent ( ) . getParent ( ) . toURL ( ) ;
Buggy code:
public class XSWildcardDecl { public static final short WILDCARD_ANY = 0 ; public static final short WILDCARD_OTHER = 1 ; public static final short WILDCARD_LIST = 2 ; public static final short WILDCARD_STRICT = 0 ; public static final short WILDCARD_LAX = 1 ; public static final short WILDCARD_SKIP = 2 ; public short fType = XSWildcardDecl . WILDCARD_ANY ; public short fProcessContents = XSWildcardDecl . WILDCARD_STRICT ; public String [ ] fNamespaceList ; public boolean allowNamespace ( String namespace ) { } public boolean isSubsetOf ( XSWildcardDecl superWildcard ) { } public XSWildcardDecl performUnionWith ( XSWildcardDecl wildcard ) { } public XSWildcardDecl performIntersectionWith ( XSWildcardDecl wildcard ) { } private boolean areSame ( XSWildcardDecl wildcard ) { } private String fDescription = null ; public String toString ( ) { if ( ( fDescription ) == null ) { String ret = null ; switch ( fType ) { case XSWildcardDecl . WILDCARD_ANY : fDescription = SchemaSymbols . ATTVAL_TWOPOUNDANY ; break ; case XSWildcardDecl . WILDCARD_OTHER : fDescription = ( ( SchemaSymbols . ATTVAL_TWOPOUNDOTHER ) + ":uri=" ) + ( fNamespaceList [ 0 ] ) ; break ; case XSWildcardDecl . WILDCARD_LIST : { StringBuffer buffer = new StringBuffer ( ) ; buffer . append ( ( "namespace:uri=" + ( fNamespaceList [ 0 ] ) ) ) ; for ( int i = 1 ; i < ( fNamespaceList . length ) ; i ++ ) buffer . append ( ( "," + ( fNamespaceList [ i ] ) ) ) ; fDescription = buffer . toString ( ) ; break ; } } } <START_BUG> return fDecription ; <END_BUG> } }

Fix:
return fDescription ;
Buggy code:
public class CloseDialog extends EnhancedDialog { public CloseDialog ( View view ) { } public boolean isOK ( ) { } public void ok ( ) { } public void cancel ( ) { } private View view ; private JList bufferList ; private DefaultListModel bufferModel ; private JButton selectAll ; private JButton save ; private JButton discard ; private JButton cancel ; private boolean ok ; boolean selectAllFlag ; private void updateButtons ( ) { } class ActionHandler implements ActionListener { public void actionPerformed ( ActionEvent evt ) { } } class ListHandler implements ListSelectionListener { public void valueChanged ( ListSelectionEvent evt ) { if ( selectAllFlag ) return ; int index = bufferList . getSelectedIndex ( ) ; if ( index != ( - 1 ) ) <START_BUG> view . setBuffer ( jEdit . getBuffer ( ( ( String ) ( bufferModel . getElementAt ( index ) ) ) ) ) ; <END_BUG> updateButtons ( ) ; } } }

Fix:
view . goToBuffer ( jEdit . getBuffer ( ( ( String ) ( bufferModel . getElementAt ( index ) ) ) ) ) ;
Buggy code:
public class TestQueryExcludingSubclasses extends TestCase { private EntityManagerFactory emf ; public void setUp ( ) { <START_BUG> Map props = new HashMap ( ) ; <END_BUG> props . put ( "openjpa.MetaDataFactory" , ( ( ( ( "jpa(Types=" + ( ManyOneEntity . class . getName ( ) ) ) + ";" ) + ( ManyOneEntitySub . class . getName ( ) ) ) + ")" ) ) ; emf = Persistence . createEntityManagerFactory ( "test" , props ) ; ManyOneEntity e1 = new ManyOneEntity ( ) ; e1 . setName ( "e1" ) ; ManyOneEntity e2 = new ManyOneEntity ( ) ; e2 . setName ( "e2" ) ; ManyOneEntity invalid = new ManyOneEntity ( ) ; invalid . setName ( "invalid" ) ; ManyOneEntitySub esub1 = new ManyOneEntitySub ( ) ; esub1 . setName ( "esub1" ) ; ManyOneEntitySub esub2 = new ManyOneEntitySub ( ) ; esub2 . setName ( "esub2" ) ; ManyOneEntitySub invalidsub = new ManyOneEntitySub ( ) ; invalidsub . setName ( "invalidsub" ) ; EntityManager em = emf . createEntityManager ( ) ; em . getTransaction ( ) . begin ( ) ; em . persist ( e1 ) ; em . persist ( e2 ) ; em . persist ( invalid ) ; em . persist ( esub1 ) ; em . persist ( esub2 ) ; em . persist ( invalidsub ) ; em . getTransaction ( ) . commit ( ) ; em . close ( ) ; } public void tearDown ( ) { } public void testQuery ( ) { } public void testQueryExcludingSubclasses ( ) { } public static void main ( String [ ] args ) { } }

Fix:
Map props = new HashMap ( System . getProperties ( ) ) ;
Buggy code:
@ Ceylon @ Object class falsity extends Boolean { private static final falsity value = new falsity ( ) ; public boolean booleanValue ( ) { <START_BUG> return true ; <END_BUG> } static falsity getFalsity ( ) { } @ Override public String toString ( ) { } }

Fix:
return false ;
Buggy code:
@ WebServlet ( name = "addFriend" , urlPatterns = { "//addFriend" } ) public class addFriend extends HttpServlet { protected void processRequest ( HttpServletRequest request , HttpServletResponse response ) throws IOException , ServletException { response . setContentType ( "text//html;charset=UTF-8" ) ; response . setContentType ( "text//html;charset=UTF-8" ) ; String url ; try { Login user ; HttpSession session = request . getSession ( ) ; user = ( ( Login ) ( session . getAttribute ( "user" ) ) ) ; String p_alias = request . getParameter ( "alias" ) ; boolean areFriends = ProjectDBAO . areFriends ( user . user_alias , p_alias ) ; if ( areFriends ) { url = "//alreadyFriends.jsp" ; } else { boolean theirRequestExists = ProjectDBAO . theirRequestExists ( user . user_alias , p_alias ) ; boolean yourRequestExists = ProjectDBAO . yourRequestExists ( user . user_alias , p_alias ) ; <START_BUG> if ( ( user . user_alias ) == p_alias ) { <END_BUG> url = "//cannotBeFriendsWithSelf.jsp" ; } else if ( theirRequestExists ) { ProjectDBAO . confirmFriend ( user . user_alias , p_alias ) ; url = "//confirmFriendSuccess.jsp" ; } else if ( yourRequestExists ) { url = "//requestAlreadySent.jsp" ; } else { ProjectDBAO . sendFriendRequest ( user . user_alias , p_alias ) ; url = "//addFriendSuccess.jsp" ; } } } catch ( Exception e ) { request . setAttribute ( "errmsg" , e ) ; url = "//error.jsp" ; } getServletContext ( ) . getRequestDispatcher ( url ) . forward ( request , response ) ; } @ Override protected void doGet ( HttpServletRequest request , HttpServletResponse response ) throws IOException , ServletException { } @ Override protected void doPost ( HttpServletRequest request , HttpServletResponse response ) throws IOException , ServletException { } @ Override public String getServletInfo ( ) { } }

Fix:
if ( user . user_alias . contentEquals ( p_alias ) ) {
Buggy code:
public class OLSMultipleLinearRegression extends AbstractMultipleLinearRegression { private QRDecomposition qr = null ; public void newSampleData ( double [ ] y , double [ ] [ ] x ) { } public void newSampleData ( double [ ] data , int nobs , int nvars ) { } protected void newXSampleData ( double [ ] [ ] x ) { } protected RealMatrix calculateBeta ( ) { } protected RealMatrix calculateBetaVariance ( ) { RealMatrix XTX = X . transpose ( ) . multiply ( X ) ; <START_BUG> return new LUSolver ( new org . apache . commons . math . linear . LUDecompositionImpl ( XTX ) ) . getInverse ( ) ; <END_BUG> } protected double calculateYVariance ( ) { } private static RealMatrix solveUpperTriangular ( RealMatrix coefficients , RealMatrix constants ) { } private static boolean isUpperTriangular ( RealMatrix m , double epsilon ) { } }

Fix:
return new org . apache . commons . math . linear . LUDecompositionImpl ( XTX ) . getSolver ( ) . getInverse ( ) ;
Buggy code:
public class Table extends NameSet implements Comparable , SourceTracker { private String _name = null ; private String _schemaName = null ; private Map _colMap = null ; private Map _idxMap = null ; private Collection _fkList = null ; private Collection _unqList = null ; private Schema _schema = null ; private PrimaryKey _pk = null ; private File _source = null ; private int _srcType = SRC_OTHER ; private String _fullName = null ; private Column [ ] _cols = null ; private Column [ ] _autoAssign = null ; private Column [ ] _rels = null ; private ForeignKey [ ] _fks = null ; private Index [ ] _idxs = null ; private Unique [ ] _unqs = null ; public Table ( ) { } public Table ( String name , Schema schema ) { } void remove ( ) { } public Schema getSchema ( ) { } public String getSchemaName ( ) { } public void setSchemaName ( String name ) { } public String getName ( ) { } public void setName ( String name ) { } public String getFullName ( ) { } public File getSourceFile ( ) { } public Object getSourceScope ( ) { } public int getSourceType ( ) { } public void setSource ( File source , int srcType ) { } public String getResourceName ( ) { } public Column [ ] getColumns ( ) { } public Column [ ] getAutoAssignedColumns ( ) { } public Column [ ] getRelationIdColumns ( ) { } public Column getColumn ( String name ) { } public Column addColumn ( String name ) { } public boolean removeColumn ( Column col ) { } public Column importColumn ( Column col ) { } public PrimaryKey getPrimaryKey ( ) { } public PrimaryKey addPrimaryKey ( ) { } public PrimaryKey addPrimaryKey ( String name ) { } public boolean removePrimaryKey ( ) { } public PrimaryKey importPrimaryKey ( PrimaryKey pk ) { } public ForeignKey getForeignKey ( String name ) { } public ForeignKey [ ] getForeignKeys ( ) { } public ForeignKey addForeignKey ( ) { } public ForeignKey addForeignKey ( String name ) { } public boolean removeForeignKey ( ForeignKey fk ) { } public ForeignKey importForeignKey ( ForeignKey fk ) { } public Index [ ] getIndexes ( ) { <START_BUG> if ( ( _idxs ) == null ) <END_BUG> _idxs = ( ( _idxMap ) == null ) ? Schemas . EMPTY_INDEXES : ( ( Index [ ] ) ( _idxMap . values ( ) . toArray ( new Index [ _idxMap . size ( ) ] ) ) ) ; return _idxs ; } public Index getIndex ( String name ) { } public Index addIndex ( String name ) { } public boolean removeIndex ( Index idx ) { } public Index importIndex ( Index idx ) { } public Unique [ ] getUniques ( ) { } public Unique getUnique ( String name ) { } public Unique addUnique ( String name ) { } public boolean removeUnique ( Unique unq ) { } public Unique importUnique ( Unique unq ) { } void indexColumns ( ) { } void indexForeignKeys ( ) { } void changeAutoAssigned ( Column col ) { } void changeRelationId ( Column col ) { } public int compareTo ( Object other ) { } public String toString ( ) { } }

Fix:
if ( ( ( _idxs ) == null ) || ( ( _idxs . length ) == 0 ) )