Buggy code:
public String getCharacterEncoding ( ) { } public void setUseMultiPartContentType ( boolean useMultiPartContentType ) { } public int getContentLength ( ) { } public String getContentType ( ) { } public String getContextPath ( ) { } public Cookie [ ] getCookies ( ) { } public long getDateHeader ( final String name ) throws IllegalArgumentException { } public String getHeader ( final String name ) { } public Enumeration < String > getHeaderNames ( ) { } public Enumeration < String > getHeaders ( final String name ) { } public ServletInputStream getInputStream ( ) throws IOException { } public int getIntHeader ( final String name ) { } public Locale getLocale ( ) { } public Enumeration < Locale > getLocales ( ) { } public String getMethod ( ) { } public String getParameter ( final String name ) { } public Map < String , Object > getParameterMap ( ) { } public Enumeration < String > getParameterNames ( ) { } public String [ ] getParameterValues ( final String name ) { } public String getPathInfo ( ) { } public String getPathTranslated ( ) { } public String getProtocol ( ) { } public String getQueryString ( ) { } public BufferedReader getReader ( ) throws IOException { } @ Deprecated public String getRealPath ( String name ) { } public String getRemoteAddr ( ) { } public String getRemoteHost ( ) { } public String getRemoteUser ( ) { } public RequestDispatcher getRequestDispatcher ( String name ) { } public String getRequestedSessionId ( ) { } public String getRequestURI ( ) { } public StringBuffer getRequestURL ( ) { } public String getScheme ( ) { } public String getServerName ( ) { } public int getServerPort ( ) { } public String getServletPath ( ) { } public HttpSession getSession ( ) { } public HttpSession getSession ( boolean b ) { } public Principal getUserPrincipal ( ) { } public boolean hasUploadedFiles ( ) { } public void initialize ( ) { } public boolean isRequestedSessionIdFromCookie ( ) { } public boolean isRequestedSessionIdFromUrl ( ) { } public boolean isRequestedSessionIdFromURL ( ) { } public boolean isRequestedSessionIdValid ( ) { } public boolean isSecure ( ) { } public boolean isUserInRole ( String name ) { } public void removeAttribute ( final String name ) { } public void setAttribute ( final String name , final Object o ) { } public void setAuthType ( final String authType ) { } public void setCharacterEncoding ( final String encoding ) throws UnsupportedEncodingException { } public void setCookies ( final Cookie [ ] theCookies ) { } public void setMethod ( final String method ) { } public void setParameter ( final String name , final String value ) { } public void setParameters ( final Map < String , String [ ] > parameters ) { } public void setPath ( final String path ) { } public void setURL ( String url ) { } public void setRequestToBookmarkablePage ( final Page page , final Map < String , Object > params ) { } public void setRequestToComponent ( final Component component ) { final IPageMap pageMap = component . getPage ( ) . getPageMap ( ) ; final String pageMapName = ( pageMap . isDefault ( ) ) ? "" : pageMap . getName ( ) ; if ( component instanceof BookmarkablePageLink ) { final Class < ? extends Page > clazz = ( ( BookmarkablePageLink < ? > ) ( component ) ) . getPageClass ( ) ; parameters . put ( BOOKMARKABLE_PAGE_PARAMETER_NAME , ( ( pageMapName + ':' ) + ( clazz . getName ( ) ) ) ) ; } else { <START_BUG> int version = component . getPage ( ) . getCurrentVersionNumber ( ) ; <END_BUG> Class < ? > clazz = null ; if ( component instanceof IRedirectListener ) { clazz = IRedirectListener . class ; } else if ( component instanceof IResourceListener ) { clazz = IResourceListener . class ; } else if ( component instanceof IFormSubmitListener ) { clazz = IFormSubmitListener . class ; } else if ( component instanceof ILinkListener ) { clazz = ILinkListener . class ; } else if ( component instanceof IOnChangeListener ) { clazz = IOnChangeListener . class ; } else { throw new IllegalArgumentException ( ( "The<seq2seq4repair_space>component<seq2seq4repair_space>class<seq2seq4repair_space>doesn't<seq2seq4repair_space>seem<seq2seq4repair_space>to<seq2seq4repair_space>implement<seq2seq4repair_space>any<seq2seq4repair_space>of<seq2seq4repair_space>the<seq2seq4repair_space>known<seq2seq4repair_space>*Listener<seq2seq4repair_space>interfaces:<seq2seq4repair_space>" + ( component . getClass ( ) ) ) ) ; } parameters . put ( INTERFACE_PARAMETER_NAME , ( ( ( ( ( ( ( pageMapName + ':' ) + ( component . getPath ( ) ) ) + ':' ) + ( version == 0 ? "" : "" + version ) ) + ':' ) + ( Classes . simpleName ( clazz ) ) ) + "::" ) ) ; try { RequestListenerInterface rli = ( ( RequestListenerInterface ) ( clazz . getField ( "INTERFACE" ) . get ( clazz ) ) ) ; String auto = component . getRequestCycle ( ) . urlFor ( component , rli ) . toString ( ) ; if ( auto . startsWith ( "?x=" ) ) { auto = auto . substring ( 3 ) ; parameters . put ( "x" , auto ) ; parameters . remove ( INTERFACE_PARAMETER_NAME ) ; } else { int idx = auto . indexOf ( INTERFACE_PARAMETER_NAME ) ; if ( idx >= 0 ) { auto = auto . substring ( ( ( idx + ( INTERFACE_PARAMETER_NAME . length ( ) ) ) + 1 ) ) ; } else { idx = auto . indexOf ( "&" ) ; if ( idx >= 0 ) { auto = auto . substring ( 0 , idx ) ; } } parameters . put ( INTERFACE_PARAMETER_NAME , auto ) ; } } catch ( Exception e ) { }

Fix:
int version = 0 ;