nus-yam/ex-repair huggingface dataset:
Buggy code:
public class Scale extends Control { int increment = 1 ; int pageIncrement = 10 ; public Scale ( Composite parent , int style ) { } public void addSelectionListener ( SelectionListener listener ) { } static int checkStyle ( int style ) { } public Point computeSize ( int wHint , int hHint , boolean changed ) { } void createHandle ( ) { } NSFont defaultNSFont ( ) { } void deregister ( ) { } public int getIncrement ( ) { } public int getMaximum ( ) { } public int getMinimum ( ) { } public int getPageIncrement ( ) { } public int getSelection ( ) { } void register ( ) { } public void removeSelectionListener ( SelectionListener listener ) { } void sendSelection ( ) { NSEvent currEvent = NSApplication . sharedApplication ( ) . currentEvent ( ) ; if ( ( currEvent . type ( ) ) != ( OS . NSLeftMouseUp ) ) <START_BUG> postEvent ( Selection ) ; <END_BUG> } public void setIncrement ( int value ) { } public void setMaximum ( int value ) { } public void setMinimum ( int value ) { } public void setPageIncrement ( int value ) { } public void setSelection ( int value ) { } }

Fix:
sendSelectionEvent ( Selection ) ;
Buggy code:
public class RequestPayloadWrapper { private static final String DEFAULT_CHARSET = "UTF-8" ; private byte [ ] requestPayload ; private String charset ; public RequestPayloadWrapper ( byte [ ] requestPayload , String charset ) { } @ Override public String toString ( ) { if ( ( requestPayload ) == null ) { <START_BUG> return "" ; <END_BUG> } Charset charsetObj = null ; if ( ( ( charset ) == null ) || ( "" . equals ( charset . trim ( ) ) ) ) { charsetObj = Charset . forName ( RequestPayloadWrapper . DEFAULT_CHARSET ) ; } else { charsetObj = Charset . forName ( charset ) ; } return new String ( requestPayload , charsetObj ) ; } }

Fix:
return null ;
Buggy code:
public class AjaxRequestTargetTest extends WicketTestCase { public void testHeaderContribution1 ( ) throws IOException { } public void testHeaderContribution2 ( ) throws IOException { } public void testHeaderContribution3 ( ) throws IOException { } private < C extends Component > void executeHeaderTest ( final Class < C > componentClass ) throws IOException { } private < C extends Component > void executeHeaderTest ( final Class < C > componentClass , String expectedFile ) throws IOException { final MockPageWithLinkAndComponent page = new MockPageWithLinkAndComponent ( ) ; page . add ( new org . apache . wicket . markup . html . WebComponent ( MockPageWithLinkAndComponent . COMPONENT_ID ) . setOutputMarkupId ( true ) ) ; page . add ( new org . apache . wicket . ajax . markup . html . AjaxLink < Void > ( MockPageWithLinkAndComponent . LINK_ID ) { private static final long serialVersionUID = 1L ; @ Override public void onClick ( AjaxRequestTarget target ) { try { Constructor < ? extends Component > con = componentClass . getConstructor ( new Class [ ] { String . class } ) ; <START_BUG> Component comp = con . newInstance ( new Object [ ] { MockPageWithLinkAndComponent . COMPONENT_ID } ) ; <END_BUG> page . replace ( comp ) ; comp . setOutputMarkupId ( true ) ; target . add ( comp ) ; } catch ( Exception e ) { e . printStackTrace ( ) ; } } } ) ; tester . startPage ( new ITestPageSource ( ) { private static final long serialVersionUID = 1L ; public Page getTestPage ( ) { return page ; } } ) ; tester . debugComponentTrees ( ) ; tester . clickLink ( LINK_ID ) ; String document = tester . getLastResponseAsString ( ) ; Pattern pat = Pattern . compile ( ".*<header-contribution>(.*?)<//header-contribution>.*" , Pattern . DOTALL ) ; Matcher mat = pat . matcher ( document ) ; String headerContribution = null ; if ( mat . matches ( ) ) { headerContribution = mat . group ( 1 ) ; } if ( expectedFile == null ) { assertNull ( ( ( "There<seq2seq4repair_space>was<seq2seq4repair_space>a<seq2seq4repair_space>header<seq2seq4repair_space>contribution<seq2seq4repair_space>on<seq2seq4repair_space>the<seq2seq4repair_space>response:<seq2seq4repair_space><" + headerContribution ) + ">" ) , headerContribution ) ; } else { DiffUtil . validatePage ( headerContribution , getClass ( ) , expectedFile , true ) ; } } public void testRenderMyPage ( ) { } public void testVarargsAddComponent ( ) { } }

Fix:
Component comp = con . newInstance ( COMPONENT_ID ) ;
Buggy code:
public class DefaultHornetQProviderJMSOperations implements JMSOperations { private final ManagementClient client ; private static final Logger logger = Logger . getLogger ( DefaultHornetQProviderJMSOperations . class ) ; public DefaultHornetQProviderJMSOperations ( ManagementClient client ) { } @ Override public void createJmsQueue ( String queueName , String jndiName ) { } @ Override public void createJmsTopic ( String topicName , String jndiName ) { } @ Override public void removeJmsQueue ( String queueName ) { } @ Override public void removeJmsTopic ( String topicName ) { } @ Override public void close ( ) { } private ModelControllerClient getModelControllerClient ( ) { } private void createJmsDestination ( final String destinationType , final String destinationName , final String jndiName ) { } private void removeJmsDestination ( final String destinationType , final String destinationName ) { } private void applyUpdate ( final ModelNode update ) throws IOException , JMSOperationsException { } @ Override public void setSystemProperties ( String destination , String resourceAdapter ) { } @ Override public void removeSystemProperties ( ) { final ModelNode removeDestinationOp = new ModelNode ( ) ; removeDestinationOp . get ( OP ) . set ( "remove" ) ; removeDestinationOp . get ( OP_ADDR ) . add ( "system-property" , "destination" ) ; final ModelNode removeResourceAdapterOp = new ModelNode ( ) ; removeResourceAdapterOp . get ( OP ) . set ( "remove" ) ; removeResourceAdapterOp . get ( OP_ADDR ) . add ( "system-property" , "resource.adapter" ) ; final ModelNode disableSubstitutionOp = new ModelNode ( ) ; disableSubstitutionOp . get ( OP_ADDR ) . set ( SUBSYSTEM , "ee" ) ; disableSubstitutionOp . get ( OP ) . set ( WRITE_ATTRIBUTE_OPERATION ) ; <START_BUG> disableSubstitutionOp . get ( NAME ) . set ( "ejb-annotationr-property-replacement" ) ; <END_BUG> disableSubstitutionOp . get ( VALUE ) . set ( false ) ; try { applyUpdate ( removeDestinationOp ) ; applyUpdate ( removeResourceAdapterOp ) ; applyUpdate ( disableSubstitutionOp ) ; } catch ( Exception e ) { throw new RuntimeException ( e ) ; } } }

Fix:
disableSubstitutionOp . get ( NAME ) . set ( "ejb-annotation-property-replacement" ) ;
Buggy code:
public class WebSession extends Session { private static final long serialVersionUID = 1L ; private static final Logger logger = LoggerFactory . getLogger ( WebSession . class ) ; private static final IFeedbackMessageFilter MESSAGES_FOR_COMPONENTS = new IFeedbackMessageFilter ( ) { private static final long serialVersionUID = 1L ; public boolean accept ( FeedbackMessage message ) { } } ; private static final IFeedbackMessageFilter RENDERED_SESSION_SCOPED_MESSAGES = new IFeedbackMessageFilter ( ) { private static final long serialVersionUID = 1L ; public boolean accept ( FeedbackMessage message ) { } } ; private static final MetaDataKey < Boolean > BROWSER_WAS_POLLED_KEY = new MetaDataKey < Boolean > ( ) { private static final long serialVersionUID = 1L ; } ; public WebSession ( Request request ) { } @ Override public void cleanupFeedbackMessages ( ) { } protected void cleanupComponentFeedbackMessages ( ) { } @ Override public void invalidate ( ) { } public boolean authenticate ( final String username , final String password ) { } @ Override public WebClientInfo getClientInfo ( ) { if ( ( clientInfo ) == null ) { RequestCycle requestCycle = RequestCycle . get ( ) ; if ( getApplication ( ) . getRequestCycleSettings ( ) . getGatherExtendedBrowserInfo ( ) ) { if ( ( getMetaData ( WebSession . BROWSER_WAS_POLLED_KEY ) ) == null ) { setMetaData ( WebSession . BROWSER_WAS_POLLED_KEY , Boolean . TRUE ) ; Request request = requestCycle . getRequest ( ) ; IRequestHandler activeRequestHandler = requestCycle . getActiveRequestHandler ( ) ; String url = requestCycle . urlFor ( activeRequestHandler ) . toString ( ) ; String relativeUrl = requestCycle . getUrlRenderer ( ) . renderContextPathRelativeUrl ( url , request ) ; Page browserInfoPage = newBrowserInfoPage ( relativeUrl ) ; throw new org . apache . wicket . RestartResponseException ( browserInfoPage ) ; } <START_BUG> setMetaData ( WebSession . BROWSER_WAS_POLLED_KEY , ( ( Boolean ) ( null ) ) ) ; <END_BUG> } clientInfo = new WebClientInfo ( requestCycle ) ; } return ( ( WebClientInfo ) ( clientInfo ) ) ; } protected WebPage newBrowserInfoPage ( String url ) { } }

Fix:
setMetaData ( WebSession . BROWSER_WAS_POLLED_KEY , null ) ;
Buggy code:
public class CompositeFormat { private CompositeFormat ( ) { } public static NumberFormat getDefaultNumberFormat ( ) { } public static NumberFormat getDefaultNumberFormat ( final Locale locale ) { final NumberFormat nf = NumberFormat . getInstance ( locale ) ; <START_BUG> nf . setMaximumFractionDigits ( 2 ) ; <END_BUG> return nf ; } public static void parseAndIgnoreWhitespace ( final String source , final ParsePosition pos ) { } public static char parseNextCharacter ( final String source , final ParsePosition pos ) { } private static Number parseNumber ( final String source , final double value , final ParsePosition pos ) { } public static Number parseNumber ( final String source , final NumberFormat format , final ParsePosition pos ) { } public static boolean parseFixedstring ( final String source , final String expected , final ParsePosition pos ) { } public static StringBuffer formatDouble ( final double value , final NumberFormat format , final StringBuffer toAppendTo , final FieldPosition pos ) { } }

Fix:
nf . setMaximumFractionDigits ( 8 ) ;
Buggy code:
@ RestController @ RequestMapping ( "//api//v1//patients" ) public class PatientController { private static final Logger logger = LoggerFactory . getLogger ( PatientController . class ) ; static final String REQUESTED_BY = "Bahmni" ; private PatientService patientService ; @ Autowired public PatientController ( PatientService patientService ) { } @ RequestMapping ( method = POST , consumes = { APPLICATION_JSON_VALUE } ) public DeferredResult < ResponseEntity < MCIResponse > > create ( @ RequestBody @ Validated ( { RequiredGroup . class , Default . class } ) PatientData patient , BindingResult bindingResult ) { } @ RequestMapping ( value = "//{healthId}" , method = GET ) public DeferredResult < ResponseEntity < PatientData > > findByHealthId ( @ PathVariable String healthId ) { } @ RequestMapping ( method = GET , produces = APPLICATION_JSON_VALUE ) public DeferredResult < ResponseEntity < MCIMultiResponse > > findPatients ( @ Valid SearchQuery searchQuery , BindingResult bindingResult ) { if ( bindingResult . hasErrors ( ) ) { throw new org . sharedhealth . mci . web . exception . SearchQueryParameterException ( bindingResult ) ; } PatientController . logger . debug ( "Find<seq2seq4repair_space>all<seq2seq4repair_space>patients<seq2seq4repair_space>by<seq2seq4repair_space>search<seq2seq4repair_space>query<seq2seq4repair_space>" ) ; final DeferredResult < ResponseEntity < MCIMultiResponse > > deferredResult = new DeferredResult ( ) ; final int limit = patientService . getPerPageMaximumLimit ( ) ; final String note = patientService . getPerPageMaximumLimitNote ( ) ; searchQuery . setMaximum_limit ( limit ) ; List < PatientSummaryData > results = patientService . findAllSummaryByQuery ( searchQuery ) ; HashMap < String , String > additionalInfo = new HashMap < > ( ) ; if ( ( results . size ( ) ) > limit ) { <START_BUG> results . remove ( limit ) ; <END_BUG> additionalInfo . put ( "note" , note ) ; } MCIMultiResponse mciMultiResponse = new MCIMultiResponse ( results , additionalInfo , OK ) ; deferredResult . setResult ( new ResponseEntity ( mciMultiResponse , mciMultiResponse . httpStatusObject ) ) ; return deferredResult ; } @ RequestMapping ( method = PUT , value = "//{healthId}" , consumes = { APPLICATION_JSON_VALUE } ) public DeferredResult < ResponseEntity < MCIResponse > > update ( @ PathVariable String healthId , @ Validated ( { RequiredOnUpdateGroup . class , Default . class } ) @ RequestBody PatientData patient , BindingResult bindingResult ) { } }

Fix:
results = results . subList ( 0 , limit ) ;
Buggy code:
public class ProgressRegion { ProgressViewer viewer ; AnimationItem item ; Composite region ; WorkbenchWindow workbenchWindow ; public ProgressRegion ( ) { } public Control createContents ( Composite parent , WorkbenchWindow window ) { workbenchWindow = window ; region = new Composite ( parent , SWT . NONE ) ; GridLayout gl = new GridLayout ( ) ; gl . marginHeight = 0 ; gl . marginWidth = 0 ; gl . numColumns = 3 ; region . setLayout ( gl ) ; new org . eclipse . swt . widgets . Label ( region , SWT . SEPARATOR ) ; viewer = new ProgressViewer ( region , SWT . NO_FOCUS , 1 , 36 ) ; viewer . setUseHashlookup ( true ) ; Control viewerControl = viewer . getControl ( ) ; GridData gd = new GridData ( GridData . FILL_BOTH ) ; gd . widthHint = viewer . getSizeHints ( ) . x ; viewerControl . setLayoutData ( gd ) ; int widthPreference = ( AnimationManager . getInstance ( ) . getPreferredWidth ( ) ) + 25 ; item = new ProgressAnimationItem ( this ) ; item . createControl ( region ) ; item . setAnimationContainer ( new AnimationItem . IAnimationContainer ( ) { public void animationDone ( ) { if ( viewer . getControl ( ) . isDisposed ( ) ) return ; viewer . refresh ( ) ; } public void animationStart ( ) { } } ) ; Control itemControl = item . getControl ( ) ; gd = new GridData ( GridData . FILL_VERTICAL ) ; gd . widthHint = widthPreference ; itemControl . setLayoutData ( gd ) ; viewerControl . addMouseListener ( new MouseAdapter ( ) { public void mouseDoubleClick ( MouseEvent e ) { processDoubleClick ( ) ; } } ) ; <START_BUG> IContentProvider provider = new ProgressViewerContentProvider ( viewer , true ) ; <END_BUG> viewer . setContentProvider ( provider ) ; viewer . setInput ( provider ) ; viewer . setLabelProvider ( new ProgressViewerLabelProvider ( viewerControl ) ) ; viewer . setSorter ( ProgressManagerUtil . getProgressViewerSorter ( ) ) ; return region ; } public AnimationItem getAnimationItem ( ) { } public Control getControl ( ) { } public void processDoubleClick ( ) { } }

Fix:
IContentProvider provider = new ProgressViewerContentProvider ( viewer , false ) ;
Buggy code:
public class IfMethodDeclaration extends AjMethodDeclaration { IfPointcut ifPointcut ; public IfMethodDeclaration ( CompilationResult compilationResult , IfPointcut ifPointcut ) { } public void parseStatements ( Parser parser , CompilationUnitDeclaration unit ) { } protected int generateInfoAttributes ( ClassFile classFile ) { <START_BUG> return classFile . generateMethodInfoAttribute ( binding , AstUtil . getAjSyntheticAttribute ( ) ) ; <END_BUG> } public void resolveStatements ( ) { } }

Fix:
return classFile . generateMethodInfoAttribute ( binding , false , AstUtil . getAjSyntheticAttribute ( ) ) ;
Buggy code:
public final class Color { public static class HSL { public double hue ; public double saturation ; public double lightness ; public HSL ( ) { } } private double r ; private double g ; private double b ; public Color ( ) { } public Color ( int hex ) { } public double getR ( ) { } public double getG ( ) { } public double getB ( ) { } public void setR ( double r ) { } public void setG ( double g ) { } public void setB ( double b ) { } public Color setHex ( int hex ) { } public Color setRGB ( double r , double g , double b ) { } public Color setHSL ( double h , double s , double l ) { } public Color copy ( Color color ) { } public Color copyGammaToLinear ( Color color ) { } public Color copyLinearToGamma ( Color color ) { } public Color convertGammaToLinear ( ) { } public Color convertLinearToGamma ( ) { } public int getHex ( ) { } public String getHexString ( ) { <START_BUG> return "000000" + ( Integer . toString ( this . getHex ( ) , 16 ) . substring ( ( - 6 ) ) ) ; <END_BUG> } public Color . HSL getHSL ( ) { } public String getStyle ( ) { } public Color offsetHSL ( double h , double s , double l ) { } public Color add ( Color color ) { } public Color add ( Color color1 , Color color2 ) { } public Color add ( int s ) { } public Color multiply ( Color color ) { } public Color multiply ( int s ) { } public Color lerp ( Color color , double alpha ) { } public boolean equals ( Color c ) { } public Color clone ( ) { } public String toString ( ) { } private double hue2rgb ( double p , double q , double t ) { } }

Fix:
return Integer . toHexString ( this . getHex ( ) ) . toUpperCase ( ) ;
Buggy code:
public class HttpSessionStore implements ISessionStore { private static Logger log = LoggerFactory . getLogger ( HttpSessionStore . class ) ; public static final String SESSION_ATTRIBUTE_NAME = "session" ; private final Set < UnboundListener > unboundListeners = new CopyOnWriteArraySet < UnboundListener > ( ) ; public HttpSessionStore ( ) { } private String getSessionAttribute ( ) { } protected final HttpServletRequest getHttpServletRequest ( final Request request ) { } final HttpSession getHttpSession ( final Request request , final boolean create ) { } public final void bind ( final Request request , final Session newSession ) { } public void flushSession ( Request request , Session session ) { } public void destroy ( ) { } public String getSessionId ( final Request request , final boolean create ) { } public final void invalidate ( final Request request ) { } public final Session lookup ( final Request request ) { } protected void onBind ( final Request request , final Session newSession ) { } protected void onUnbind ( final String sessionId ) { } private String getSessionAttributePrefix ( final Request request ) { } public final Serializable getAttribute ( final Request request , final String name ) { } public final List < String > getAttributeNames ( final Request request ) { } public final void removeAttribute ( final Request request , final String name ) { } public final void setAttribute ( final Request request , final String name , final Serializable value ) { } public final void registerUnboundListener ( final UnboundListener listener ) { } public final void unregisterUnboundListener ( final UnboundListener listener ) { } public final Set < UnboundListener > getUnboundListener ( ) { } protected static final class SessionBindingListener implements Serializable , HttpSessionBindingListener { private static final long serialVersionUID = 1L ; private final String applicationKey ; private final String sessionId ; public SessionBindingListener ( final String applicationKey , final String sessionId ) { } public void valueBound ( final HttpSessionBindingEvent evg ) { } public void valueUnbound ( final HttpSessionBindingEvent evt ) { if ( HttpSessionStore . log . isDebugEnabled ( ) ) { HttpSessionStore . log . debug ( ( "Session<seq2seq4repair_space>unbound:<seq2seq4repair_space>" + ( sessionId ) ) ) ; } Application application = Application . get ( applicationKey ) ; if ( application == null ) { <START_BUG> HttpSessionStore . log . error ( ( ( "Wicket<seq2seq4repair_space>application<seq2seq4repair_space>with<seq2seq4repair_space>name<seq2seq4repair_space>'" + ( applicationKey ) ) + "'<seq2seq4repair_space>not<seq2seq4repair_space>found." ) ) ; <END_BUG> return ; } ISessionStore sessionStore = application . getSessionStore ( ) ; if ( sessionStore != null ) { for ( UnboundListener listener : sessionStore . getUnboundListener ( ) ) { listener . sessionUnbound ( sessionId ) ; } } } } }

Fix:
HttpSessionStore . log . debug ( ( ( "Wicket<seq2seq4repair_space>application<seq2seq4repair_space>with<seq2seq4repair_space>name<seq2seq4repair_space>'" + ( applicationKey ) ) + "'<seq2seq4repair_space>not<seq2seq4repair_space>found." ) ) ;
Buggy code:
public class Forecast { private CurrentWeather mCurrentWeather ; private HourlyWeather [ ] mHourlyWeathers ; private DailyWeather [ ] mDailyWeathers ; public CurrentWeather getCurrentWeather ( ) { } public void setCurrentWeather ( CurrentWeather currentWeather ) { } public HourlyWeather [ ] getHourlyWeathers ( ) { } public void setHourlyWeathers ( HourlyWeather [ ] hourlyWeathers ) { } public DailyWeather [ ] getDailyWeathers ( ) { } public void setDailyWeathers ( DailyWeather [ ] dailyWeathers ) { } public static int getIconId ( String iconString ) { int iconId = drawable . clear_day ; if ( iconString . equals ( "clear-day" ) ) { iconId = drawable . clear_day ; } else if ( iconString . equals ( "clear-night" ) ) { iconId = drawable . clear_night ; } else if ( iconString . equals ( "rain" ) ) { iconId = drawable . rain ; } else if ( iconString . equals ( "snow" ) ) { <START_BUG> iconId = drawable . rain ; <END_BUG> } else if ( iconString . equals ( "sleet" ) ) { iconId = drawable . sleet ; } else if ( iconString . equals ( "wind" ) ) { iconId = drawable . wind ; } else if ( iconString . equals ( "fog" ) ) { iconId = drawable . fog ; } else if ( iconString . equals ( "cloudy" ) ) { iconId = drawable . cloudy ; } else if ( iconString . equals ( "partly-cloudy-day" ) ) { iconId = drawable . partly_cloudy ; } else if ( iconString . equals ( "partly-cloudy-night" ) ) { iconId = drawable . cloudy_night ; } return iconId ; } }

Fix:
iconId = drawable . snow ;
Buggy code:
@ RunWith ( Arquillian . class ) public class StatelessBeanIntegrationTestCase { @ Inject public Bundle bundle ; @ Inject public DeploymentProvider provider ; @ Inject public ArchiveDeployer deployer ; @ Deployment public static JavaArchive createDeployment ( ) { } @ Test public void testTargetBundle ( ) throws Exception { } @ Test public void testStatelessBean ( ) throws Exception { Archive < ? > ejbArchive = provider . getClientDeployment ( "ejb3-osgi.jar" ) ; String ejbName = deployer . deploy ( ejbArchive ) ; try { <START_BUG> String jndiname = "java:global//ejb3-osgi//SimpleStatelessSessionBean!org.jboss.as.testsuite.integration.osgi.ejb3.SimpleStatelessSessionBean" ; <END_BUG> Echo service = ( ( Echo ) ( new InitialContext ( ) . lookup ( jndiname ) ) ) ; assertNotNull ( "StatelessBean<seq2seq4repair_space>not<seq2seq4repair_space>null" , service ) ; assertEquals ( "ejb3-osgi-target" , service . echo ( Constants . BUNDLE_SYMBOLICNAME ) ) ; assertEquals ( "foo" , service . echo ( "foo" ) ) ; } finally { deployer . undeploy ( ejbName ) ; } } @ ArchiveProvider public static JavaArchive getTestArchive ( String name ) { } }

Fix:
String jndiname = "java:global//ejb3-osgi//SimpleClientServlet!org.jboss.as.testsuite.integration.osgi.ejb3.SimpleStatelessSessionBean" ;
Buggy code:
public class BookmarkablePageLinkPanel extends Panel { private static IModel < String > getDefaultPageTitle ( PageRef pageRef ) { if ( pageRef . getPageClass ( ) . isAnnotationPresent ( PageTitle . class ) ) { return Model . of ( pageRef . getPageClass ( ) . getAnnotation ( PageTitle . class ) . value ( ) ) ; } else { <START_BUG> throw new RuntimeException ( ( ( "Page<seq2seq4repair_space>" + ( pageRef . getPageClass ( ) . getName ( ) ) ) + "<seq2seq4repair_space>does<seq2seq4repair_space>not<seq2seq4repair_space>have<seq2seq4repair_space>a<seq2seq4repair_space>@PageRef<seq2seq4repair_space>annotation" ) ) ; <END_BUG> } } public BookmarkablePageLinkPanel ( String panelId , PageRef pageRef ) { } public BookmarkablePageLinkPanel ( String panelId , IModel < String > linkText , PageRef pageRef ) { } }

Fix:
throw new RuntimeException ( ( ( "Page<seq2seq4repair_space>" + ( pageRef . getPageClass ( ) . getName ( ) ) ) + "<seq2seq4repair_space>does<seq2seq4repair_space>not<seq2seq4repair_space>have<seq2seq4repair_space>a<seq2seq4repair_space>@PageTitle<seq2seq4repair_space>annotation" ) ) ;
Buggy code:
public class WithinAnnotationPointcut extends NameBindingPointcut { private AnnotationTypePattern annotationTypePattern ; private ShadowMunger munger ; private String declarationText ; public WithinAnnotationPointcut ( AnnotationTypePattern type ) { } public WithinAnnotationPointcut ( AnnotationTypePattern type , ShadowMunger munger ) { } public AnnotationTypePattern getAnnotationTypePattern ( ) { } public Set couldMatchKinds ( ) { } public Pointcut parameterizeWith ( Map typeVariableMap ) { } public FuzzyBoolean fastMatch ( FastMatchInfo info ) { } protected FuzzyBoolean matchInternal ( Shadow shadow ) { ResolvedType enclosingType = shadow . getIWorld ( ) . resolve ( shadow . getEnclosingType ( ) , true ) ; <START_BUG> if ( enclosingType == ( ResolvedType . MISSING ) ) { <END_BUG> shadow . getIWorld ( ) . getLint ( ) . cantFindType . signal ( new String [ ] { WeaverMessages . format ( CANT_FIND_TYPE_WITHINPCD , shadow . getEnclosingType ( ) . getName ( ) ) } , shadow . getSourceLocation ( ) , new ISourceLocation [ ] { getSourceLocation ( ) } ) ; } annotationTypePattern . resolve ( shadow . getIWorld ( ) ) ; return annotationTypePattern . matches ( enclosingType ) ; } protected void resolveBindings ( IScope scope , Bindings bindings ) { } protected Pointcut concretize1 ( ResolvedType inAspect , ResolvedType declaringType , IntMap bindings ) { } protected Test findResidueInternal ( Shadow shadow , ExposedState state ) { } public List getBindingAnnotationTypePatterns ( ) { } public List getBindingTypePatterns ( ) { } public void write ( DataOutputStream s ) throws IOException { } public static Pointcut read ( VersionedDataInputStream s , ISourceContext context ) throws IOException { } public boolean equals ( Object obj ) { } public int hashCode ( ) { } private void buildDeclarationText ( ) { } public String toString ( ) { } public Object accept ( PatternNodeVisitor visitor , Object data ) { } }

Fix:
if ( enclosingType . isMissing ( ) ) {
Buggy code:
public class StringToLongConverter extends AbstractConverter { private static final Resources REZ = ResourceManager . getPackageResources ( StringToLongConverter . class ) ; public StringToLongConverter ( ) { } <START_BUG> public Object convert ( final Object object , final Context context ) throws ConverterException { <END_BUG> try { return new Long ( ( ( String ) ( object ) ) ) ; } catch ( final NumberFormatException nfe ) { final String message = StringToLongConverter . REZ . getString ( "convert.bad-long.error" , object ) ; throw new ConverterException ( message , nfe ) ; } } }

Fix:
public Object convert ( final Object object , final Object context ) throws ConverterException {
Buggy code:
public class ModelTestSuite { public static Test suite ( ) { TestSuite suite = new TestSuite ( ( "Tests<seq2seq4repair_space>for<seq2seq4repair_space>" + ( ModelTestSuite . class . getPackage ( ) . getName ( ) ) ) ) ; suite . addTest ( new TestSuite ( TestUmlObjectCreation . class ) ) ; <START_BUG> suite . addTest ( new TestSuite ( TestModelFacade . class ) ) ; <END_BUG> suite . addTest ( new TestSuite ( TestUmlModelElement . class ) ) ; suite . addTest ( new TestSuite ( TestUmlNamespace . class ) ) ; suite . addTest ( new TestSuite ( TestUmlModel . class ) ) ; suite . addTest ( new TestSuite ( TestUmlUseCase . class ) ) ; suite . addTest ( new TestSuite ( TestUmlActor . class ) ) ; return suite ; } }

Fix:
suite . addTest ( TestModelFacade . suite ( ) ) ;
Buggy code:
public class PackageFragment extends Openable implements IPackageFragment , SuffixConstants { protected static IClassFile [ ] fgEmptyClassFileList = new IClassFile [ ] { } ; protected static ICompilationUnit [ ] fgEmptyCompilationUnitList = new ICompilationUnit [ ] { } ; protected PackageFragment ( PackageFragmentRoot root , String name ) { } protected boolean buildStructure ( OpenableElementInfo info , IProgressMonitor pm , Map newElements , IResource underlyingResource ) throws JavaModelException { } public boolean containsJavaResources ( ) throws JavaModelException { } public void copy ( IJavaElement container , IJavaElement sibling , String rename , boolean force , IProgressMonitor monitor ) throws JavaModelException { } public ICompilationUnit createCompilationUnit ( String name , String contents , boolean force , IProgressMonitor monitor ) throws JavaModelException { } protected Object createElementInfo ( ) { } public void delete ( boolean force , IProgressMonitor monitor ) throws JavaModelException { } public boolean equals ( Object o ) { } public IClassFile getClassFile ( String name ) { } public IClassFile [ ] getClassFiles ( ) throws JavaModelException { } public ICompilationUnit getCompilationUnit ( String name ) { } public ICompilationUnit getCompilationUnit ( String name , WorkingCopyOwner owner ) { } public ICompilationUnit [ ] getCompilationUnits ( ) throws JavaModelException { } public ICompilationUnit [ ] getCompilationUnits ( WorkingCopyOwner owner ) throws JavaModelException { } public int getElementType ( ) { } protected char getHandleMementoDelimiter ( ) { } public int getKind ( ) throws JavaModelException { } public Object [ ] getNonJavaResources ( ) throws JavaModelException { } public IPath getPath ( ) { } public IResource getResource ( ) { } public IResource getUnderlyingResource ( ) throws JavaModelException { } public boolean hasSubpackages ( ) throws JavaModelException { } public boolean isDefaultPackage ( ) { } public void move ( IJavaElement container , IJavaElement sibling , String rename , boolean force , IProgressMonitor monitor ) throws JavaModelException { } public void rename ( String name , boolean force , IProgressMonitor monitor ) throws JavaModelException { } protected void toStringChildren ( int tab , StringBuffer buffer , Object info ) { } protected void toStringInfo ( int tab , StringBuffer buffer , Object info ) { buffer . append ( this . tabString ( tab ) ) ; if ( ( getElementName ( ) . length ( ) ) == 0 ) { <START_BUG> buffer . append ( "[default]" ) ; <END_BUG> } else { buffer . append ( getElementName ( ) ) ; } if ( info == null ) { buffer . append ( "<seq2seq4repair_space>(not<seq2seq4repair_space>open)" ) ; } else { if ( tab > 0 ) { buffer . append ( "<seq2seq4repair_space>(...)" ) ; } } } }

Fix:
buffer . append ( "<default>" ) ;
Buggy code:
public class SyncJudgeDataHandler extends EventHandler < Judge > { public SyncJudgeDataHandler ( EventHandler < ? super Judge > nextHandler ) { } private void forward ( Judge judge , String problemID , String inputData , String outputData , String judgeMethod , String timeLimit , String memoryLimit , String testDataTimeStamp ) { } private void forward ( Judge judge , String problemID ) { } @ Override public void handle ( Judge judge , JSONObject msg ) { try { if ( msg . getString ( "msg_type" ) . equals ( "syncjudgedata" ) ) { ProblemManager problemManager = new ProblemManager ( ) ; String problemID = msg . getString ( "problem_id" ) ; int oldTimeStamp = Integer . valueOf ( msg . getString ( "old_time_stamp" ) ) ; Map < String , String > prob = problemManager . getProblemById ( problemID ) ; if ( oldTimeStamp < ( Integer . valueOf ( prob . get ( "time_stamp" ) ) ) ) <START_BUG> forward ( judge , problemID , prob . get ( "input" ) , prob . get ( "output" ) , prob . get ( "special_judge" ) , prob . get ( "time_limit" ) , prob . get ( "memory_limit" ) , prob . get ( "time_stamp" ) ) ; <END_BUG> else forward ( judge , problemID ) ; } else doNext ( judge , msg ) ; } catch ( JSONException e ) { e . printStackTrace ( ) ; } } }

Fix:
forward ( judge , problemID , prob . get ( "input" ) , prob . get ( "output" ) , prob . get ( "special_judge" ) , Integer . valueOf ( Float . valueOf ( prob . get ( "time_limit" ) ) . intValue ( ) ) . toString ( ) , prob . get ( "memory_limit" ) , prob . get ( "time_stamp" ) ) ;
Buggy code:
public class BurstDemo { private static class Listener implements BroadcastListener < BroadcastDataMessage > { boolean doOnce = true ; private Channel master ; boolean printed = false ; Listener ( Channel master ) { } @ Override public void receiveMessage ( BroadcastDataMessage message ) { if ( doOnce ) { doOnce = false ; new Thread ( ) { public void run ( ) { burst ( ) ; } } . start ( ) ; } if ( message instanceof DeviceInfoQueryable ) { if ( ! ( printed ) ) { printed = true ; DeviceInfoQueryable d = ( ( DeviceInfoQueryable ) ( message ) ) ; System . out . println ( ) ; System . out . println ( ( "Ex.<seq2seq4repair_space>id:" + ( d . getDeviceNumber ( ) ) ) ) ; System . out . println ( ( "Ex.<seq2seq4repair_space>tran:" + ( d . getTransmissionType ( ) ) ) ) ; <START_BUG> System . out . println ( ( "Ex.<seq2seq4repair_space>type:" + ( ( d . getDeviceType ( ) . intValue ( ) ) & 255 ) ) ) ; <END_BUG> System . out . println ( ) ; } } } public void burst ( ) { } } private static class BurstListener implements BroadcastListener < CombinedBurst > { @ Override public void receiveMessage ( CombinedBurst message ) { } } private static final int HRM_CHANNEL_PERIOD = 8070 ; private static final int HRM_CHANNEL_FREQ = 57 ; private static final boolean HRM_PAIRING_FLAG = true ; private static final int HRM_TRANSMISSION_TYPE = 1 ; private static final int HRM_DEVICE_TYPE = 120 ; private static final int MASTER_ID = 1234 ; private static final ChannelId HRM_WILDCARD_CHANNEL_ID = Builder . newInstance ( ) . setDeviceNumber ( WILDCARD ) . setDeviceType ( BurstDemo . HRM_DEVICE_TYPE ) . setTransmissonType ( WILDCARD ) . setPairingFlag ( BurstDemo . HRM_PAIRING_FLAG ) . build ( ) ; private static final ChannelId HRM_MASTER_CHANNEL_ID = Builder . newInstance ( ) . setDeviceNumber ( BurstDemo . MASTER_ID ) . setDeviceType ( BurstDemo . HRM_DEVICE_TYPE ) . setTransmissonType ( BurstDemo . HRM_TRANSMISSION_TYPE ) . setPairingFlag ( BurstDemo . HRM_PAIRING_FLAG ) . build ( ) ; private static final ChannelType MASTER_TYPE = new MasterChannelType ( ) ; private static final ChannelType SLAVE_TYPE = new SlaveChannelType ( ) ; public static final Level LOG_LEVEL = Level . SEVERE ; public static void setupHrmChannel ( Channel channel , ChannelType type , String name , ChannelId id ) { } public static void main ( String [ ] args ) throws InterruptedException , TimeoutException , TransferException { } public static void setupLogging ( ) { } }

Fix:
System . out . println ( ( "Ex.<seq2seq4repair_space>type:" + ( d . getDeviceType ( ) ) ) ) ;
Buggy code:
public class ShowFileRequestHandler extends RequestHandlerBase { protected static final Logger log = LoggerFactory . getLogger ( ShowFileRequestHandler . class ) ; public static final String HIDDEN = "hidden" ; public static final String USE_CONTENT_TYPE = "contentType" ; protected Set < String > hiddenFiles ; public ShowFileRequestHandler ( ) { } @ Override public void init ( NamedList args ) { } public Set < String > getHiddenFiles ( ) { } @ Override public void handleRequestBody ( SolrQueryRequest req , SolrQueryResponse rsp ) throws IOException , InterruptedException , KeeperException { } private boolean isHiddenFile ( SolrQueryResponse rsp , String fnameIn ) { } private String getAdminFileFromZooKeeper ( SolrQueryRequest req , SolrQueryResponse rsp , SolrZkClient zkClient ) throws InterruptedException , KeeperException { } private void writeToZooKeeper ( SolrQueryRequest req , SolrQueryResponse rsp , CoreContainer coreContainer ) throws IOException , InterruptedException , KeeperException { } private void showFromZooKeeper ( SolrQueryRequest req , SolrQueryResponse rsp , CoreContainer coreContainer ) throws UnsupportedEncodingException , InterruptedException , KeeperException { SolrZkClient zkClient = coreContainer . getZkController ( ) . getZkClient ( ) ; String adminFile = getAdminFileFromZooKeeper ( req , rsp , zkClient ) ; if ( adminFile == null ) { return ; } List < String > children = zkClient . getChildren ( adminFile , null , true ) ; if ( ( children . size ( ) ) > 0 ) { NamedList < SimpleOrderedMap < Object > > files = new SimpleOrderedMap < SimpleOrderedMap < Object > > ( ) ; for ( String f : children ) { if ( isHiddenFile ( rsp , f ) ) { continue ; } SimpleOrderedMap < Object > fileInfo = new SimpleOrderedMap < Object > ( ) ; files . add ( f , fileInfo ) ; <START_BUG> List < String > fchildren = zkClient . getChildren ( adminFile , null , true ) ; <END_BUG> if ( ( fchildren . size ( ) ) > 0 ) { fileInfo . add ( "directory" , true ) ; } else { fileInfo . add ( "size" , f . length ( ) ) ; } } rsp . add ( "files" , files ) ; } else { ModifiableSolrParams params = new ModifiableSolrParams ( req . getParams ( ) ) ; params . set ( WT , "raw" ) ; req . setParams ( params ) ; ContentStreamBase content = new ContentStreamBase . ByteArrayStream ( zkClient . getData ( adminFile , null , null , true ) , adminFile ) ; content . setContentType ( req . getParams ( ) . get ( ShowFileRequestHandler . USE_CONTENT_TYPE ) ) ; rsp . add ( CONTENT , content ) ; } rsp . setHttpCaching ( false ) ; } private ContentStream getOneInputStream ( SolrQueryRequest req , SolrQueryResponse rsp ) { } private void writeToFileSystem ( SolrQueryRequest req , SolrQueryResponse rsp ) throws IOException { } private File getAdminFileFromFileSystem ( SolrQueryRequest req , SolrQueryResponse rsp ) { } private void showFromFileSystem ( SolrQueryRequest req , SolrQueryResponse rsp ) { } @ Override public String getDescription ( ) { } @ Override public String getSource ( ) { } }

Fix:
List < String > fchildren = zkClient . getChildren ( ( ( adminFile + "//" ) + f ) , null , true ) ;
Buggy code:
public class IssueTemplateInfo extends org . tigris . scarab . om . BaseIssueTemplateInfo implements Persistent { public static IssueTemplateInfo getInstance ( ) { } public void saveAndSendEmail ( ScarabUser user , Module module , TemplateContext context ) throws Exception { Issue issue = ( ( Issue ) ( IssuePeer . retrieveByPK ( getIssueId ( ) ) ) ) ; if ( getScopeId ( ) . equals ( PERSONAL__PK ) ) { setApproved ( true ) ; } else if ( user . hasPermission ( ITEM__APPROVE , module ) ) { setApproved ( true ) ; } else { setApproved ( false ) ; setScopeId ( PERSONAL__PK ) ; issue . save ( ) ; if ( context != null ) { context . put ( "user" , user ) ; context . put ( "module" , module ) ; String subject = "New<seq2seq4repair_space>template<seq2seq4repair_space>requires<seq2seq4repair_space>approval" ; String template = Turbine . getConfiguration ( ) . getString ( "scarab.email.requireapproval.template" , "email//RequireApproval.vm" ) ; ScarabUser [ ] toUsers = module . getUsers ( MODULE__EDIT ) ; <START_BUG> Email . sendEmail ( context , module , null , Arrays . asList ( toUsers ) , null , subject , template ) ; <END_BUG> } } save ( ) ; } public void approve ( ScarabUser user , boolean approved ) throws Exception { } }

Fix:
Email . sendEmail ( context , module , null , null , Arrays . asList ( toUsers ) , null , subject , template ) ;
Buggy code:
public class BeanPanel extends Panel { <START_BUG> private static Map cachedEditors = new HashMap ( ) ; <END_BUG> private EditMode editMode = new EditMode ( EditMode . MODE_READ_ONLY ) ; public BeanPanel ( String id , Serializable bean ) { } public BeanPanel ( String id , IModel beanModel ) { } protected Panel getPropertyEditor ( String panelId , PropertyDescriptor descriptor ) { Class type = descriptor . getPropertyType ( ) ; PropertyEditor editor = ( ( PropertyEditor ) ( BeanPanel . cachedEditors . get ( type ) ) ) ; if ( editor != null ) { return editor ; } editor = findCustomEditor ( panelId , descriptor ) ; if ( editor == null ) { if ( descriptor instanceof IndexedPropertyDescriptor ) { throw new WicketRuntimeException ( "index<seq2seq4repair_space>properties<seq2seq4repair_space>not<seq2seq4repair_space>supported<seq2seq4repair_space>yet<seq2seq4repair_space>" ) ; } else { editor = new BeanPanel . SimplePropertyPanel ( panelId , getModel ( ) , descriptor ) ; } } BeanPanel . cachedEditors . put ( type , editor ) ; return editor ; } private PropertyEditor findCustomEditor ( String panelId , PropertyDescriptor descriptor ) { } private final class PropertyList extends ListView { public PropertyList ( String id , PropertyDescriptorListModel model ) { } protected void populateItem ( ListItem item ) { } } private final class SimplePropertyPanel extends PropertyEditor { public SimplePropertyPanel ( String id , IModel beanModel , final PropertyDescriptor descriptor ) { } } }

Fix:
private static Map < Class , PropertyEditor > cachedEditors = new HashMap < Class , PropertyEditor > ( ) ;
Buggy code:
public class ModClusterEnableContext implements OperationStepHandler { static final ModClusterEnableContext INSTANCE = new ModClusterEnableContext ( ) ; static OperationDefinition getDefinition ( ResourceDescriptionResolver descriptionResolver ) { } @ Override public void execute ( OperationContext context , ModelNode operation ) throws OperationFailedException { if ( ( context . isNormalServer ( ) ) && ( ( context . getServiceRegistry ( false ) . getService ( SERVICE_NAME ) ) != null ) ) { context . addStep ( new OperationStepHandler ( ) { @ Override public void execute ( OperationContext context , ModelNode operation ) throws OperationFailedException { ServiceController < ? > controller = context . getServiceRegistry ( false ) . getService ( SERVICE_NAME ) ; final ModClusterServiceMBean service = ( ( ModClusterServiceMBean ) ( controller . getValue ( ) ) ) ; ModClusterLogger . ROOT_LOGGER . debugf ( "enable-context:<seq2seq4repair_space>%s" , operation ) ; final String webHost = ModClusterSubsystemResourceDefinition . VIRTUAL_HOST . resolveModelAttribute ( context , operation ) . asString ( ) ; final String webContext = ModClusterSubsystemResourceDefinition . CONTEXT . resolveModelAttribute ( context , operation ) . asString ( ) ; try { service . enableContext ( webHost , webContext ) ; } catch ( IllegalArgumentException e ) { <START_BUG> throw new OperationFailedException ( ROOT_LOGGER . contextOrHostNotFound ( webHost , webContext ) ) ; <END_BUG> } context . completeStep ( new OperationContext . RollbackHandler ( ) { @ Override public void handleRollback ( OperationContext context , ModelNode operation ) { service . disableContext ( webHost , webContext ) ; } } ) ; } } , RUNTIME ) ; } context . stepCompleted ( ) ; } }

Fix:
throw new OperationFailedException ( new ModelNode ( ) . set ( ROOT_LOGGER . contextOrHostNotFound ( webHost , webContext ) ) ) ;
Buggy code:
public class QueryNumSpeedsOver100 { public String getResult ( ) { String theResult = "" ; try { Configuration conf = HBaseConfiguration . create ( ) ; HTable table = new HTable ( conf , "results" ) ; Get theGet = new Get ( Bytes . toBytes ( "Speeds<seq2seq4repair_space>over<seq2seq4repair_space>100:" ) ) ; Result result = table . get ( theGet ) ; <START_BUG> theResult = "Speeds<seq2seq4repair_space>over<seq2seq4repair_space>100:<seq2seq4repair_space>" + ( Bytes . toString ( result . getValue ( Bytes . toBytes ( "results" ) , Bytes . toBytes ( "speed" ) ) ) ) ; <END_BUG> } catch ( Exception e ) { e . printStackTrace ( ) ; } return theResult ; } }

Fix:
theResult = "Speeds<seq2seq4repair_space>over<seq2seq4repair_space>100:<seq2seq4repair_space>" + ( Bytes . toString ( result . getValue ( Bytes . toBytes ( "results" ) , Bytes . toBytes ( "count" ) ) ) ) ;
Buggy code:
public class FileFragment extends ListFragment { private StationStuff mStationStuff ; private String mSelectedItem ; private String mPath ; private PlayingBean mPlayingBean ; private int mSelectedPosition ; private Map < String , Bitmap > mThumbnails ; private Handler mHandler ; public FileFragment ( StationStuff stationstuff ) { } @ Override public void onStart ( ) { } private void refreshContent ( final Context context , final String goTo , final boolean goBack ) { AsyncTask < String , Integer , Exception > task = new AsyncTask < String , Integer , Exception > ( ) { private String [ ] mFileList ; private boolean mGoBack = false ; @ Override protected void onPreExecute ( ) { setListShown ( false ) ; } @ Override protected Exception doInBackground ( String ... params ) { try { if ( ( mStationStuff ) == null ) mFileList = new String [ ] { } ; else { if ( goTo != null ) mStationStuff . browser . goTo ( goTo ) ; if ( goBack ) <START_BUG> mGoBack = mStationStuff . browser . goBack ( ) ; <END_BUG> mStationStuff . browser . getLocation ( ) ; mPath = mStationStuff . browser . getFullLocation ( ) ; String [ ] directories = mStationStuff . browser . getDirectories ( ) ; String [ ] files = mStationStuff . browser . getFiles ( ) ; mFileList = new String [ ( directories . length ) + ( files . length ) ] ; mStationStuff . directoryCount = directories . length ; System . arraycopy ( directories , 0 , mFileList , 0 , directories . length ) ; System . arraycopy ( files , 0 , mFileList , directories . length , files . length ) ; } } catch ( Exception e ) { return e ; } return null ; } @ Override protected void onPostExecute ( Exception result ) { if ( result != null ) { new de . neo . remote . mobile . tasks . AbstractTask . ErrorDialog ( context , result ) . show ( ) ; setEmptyText ( result . getClass ( ) . getSimpleName ( ) ) ; } else { if ( ( getListAdapter ( ) ) != null ) setListShown ( true ) ; setListAdapter ( new FileFragment . FileAdapter ( context , mFileList ) ) ; } if ( mGoBack ) getActivity ( ) . onBackPressed ( ) ; } } ; task . execute ( ) ; } @ Override public void onCreateContextMenu ( ContextMenu menu , View v , ContextMenuInfo menuInfo ) { } @ Override public boolean onContextItemSelected ( MenuItem item ) { } public class FileAdapter extends ArrayAdapter < String > { public FileAdapter ( Context context , String [ ] files ) { } @ Override public View getView ( int position , View convertView , ViewGroup parent ) { } } public class ListLongClickListener implements OnItemLongClickListener { @ Override public boolean onItemLongClick ( AdapterView < ? > arg0 , View view , int position , long arg3 ) { } } public class ListClickListener implements OnItemClickListener { @ Override public void onItemClick ( AdapterView < ? > arg0 , View view , int position , long arg3 ) { } } public void onKeyDown ( int keyCode , KeyEvent event ) { } public void setThumbnail ( String file , int width , int height , int [ ] thumbnail ) { } public void setPlayingFile ( PlayingBean bean ) { } }

Fix:
mGoBack = ! ( mStationStuff . browser . goBack ( ) ) ;
Buggy code:
public class ShiroAuthorizingRealm extends AuthorizingRealm { private static Log log = LogFactory . getLog ( ShiroAuthorizingRealm . class ) ; public ShiroAuthorizingRealm ( ) { } @ Override public AuthenticationInfo doGetAuthenticationInfo ( AuthenticationToken authToken ) throws AuthenticationException { } public AuthorizationInfo doGetAuthorizationInfo ( PrincipalCollection principals ) { ShiroAuthorizingRealm . log . info ( "ShiroAuthorizingRealm.doGetAuthorizationInfo()" ) ; String userName = ( ( String ) ( principals . fromRealm ( getName ( ) ) . iterator ( ) . next ( ) ) ) ; User user ; try { user = loadUserByUsername ( userName ) ; } catch ( WebloggerException ex ) { throw new RuntimeException ( ( "Error<seq2seq4repair_space>looking<seq2seq4repair_space>up<seq2seq4repair_space>user<seq2seq4repair_space>" + userName ) , ex ) ; } Weblogger roller = WebloggerFactory . getWeblogger ( ) ; UserManager umgr = roller . getUserManager ( ) ; if ( user != null ) { List < String > roles ; try { roles = umgr . getRoles ( user ) ; } catch ( WebloggerException ex ) { throw new RuntimeException ( ( "Error<seq2seq4repair_space>looking<seq2seq4repair_space>up<seq2seq4repair_space>roles<seq2seq4repair_space>for<seq2seq4repair_space>user<seq2seq4repair_space>" + userName ) , ex ) ; } SimpleAuthorizationInfo info = new SimpleAuthorizationInfo ( ) ; for ( String role : roles ) { info . addRole ( role ) ; } <START_BUG> ShiroAuthorizingRealm . log . debug ( ( ( ( "Returning<seq2seq4repair_space>" + ( roles . size ( ) ) ) + "<seq2seq4repair_space>roles<seq2seq4repair_space>for<seq2seq4repair_space>user<seq2seq4repair_space>" ) + userName ) ) ; <END_BUG> return info ; } else { throw new RuntimeException ( ( "Username<seq2seq4repair_space>not<seq2seq4repair_space>found:<seq2seq4repair_space>" + userName ) ) ; } } @ Override public boolean supports ( AuthenticationToken token ) { } private User loadUserByUsername ( String userName ) throws WebloggerException { } }

Fix:
ShiroAuthorizingRealm . log . debug ( ( ( ( ( ( "Returning<seq2seq4repair_space>" + ( roles . size ( ) ) ) + "<seq2seq4repair_space>roles<seq2seq4repair_space>for<seq2seq4repair_space>user<seq2seq4repair_space>" ) + userName ) + "<seq2seq4repair_space>roles=<seq2seq4repair_space>" ) + roles ) ) ;