Buggy code:
public class AntStarTeamCheckOut extends org . apache . tools . ant . Task { public static final String DEFAULT_INCLUDESETTING = "*" ; public static final String DEFAULT_EXCLUDESETTING = null ; public static final String DEFAULT_FOLDERSETTING = null ; private Folder prevFolder = null ; private int checkedOut = 0 ; private String serverName = null ; private int serverPort = - 1 ; private String projectName = null ; private String folderName = AntStarTeamCheckOut . DEFAULT_FOLDERSETTING ; private String viewName = null ; private String username = null ; private String password = null ; private String targetFolder = null ; private boolean force = false ; private boolean verbose = false ; private boolean recursion = true ; private String includes = AntStarTeamCheckOut . DEFAULT_INCLUDESETTING ; private String excludes = AntStarTeamCheckOut . DEFAULT_EXCLUDESETTING ; private String delim = Platform . getFilePathDelim ( ) ; private boolean targetFolderAbsolute = false ; private static void assertTrue ( boolean value , String msg ) throws BuildException { } protected void checkParameters ( ) throws BuildException { } public void execute ( ) throws BuildException { } protected Server getServer ( ) { } protected void runServer ( Server s ) { } protected void runProject ( Server s , Project p ) { View [ ] views = p . getViews ( ) ; for ( int i = 0 ; i < ( views . length ) ; i ++ ) { View v = views [ i ] ; if ( v . getName ( ) . equals ( getViewName ( ) ) ) { if ( getVerbose ( ) ) { log ( ( ( ( ( "Found<seq2seq4repair_space>" + ( getProjectName ( ) ) ) + ( delim ) ) + ( getViewName ( ) ) ) + ( delim ) ) ) ; } <START_BUG> runType ( s , p , v , s . typeForName ( ( ( String ) ( s . getTypeNames ( ) . FILE ) ) ) ) ; <END_BUG> break ; } } } protected void runType ( Server s , Project p , View v , Type t ) { } private File calcTargetFolder ( View v , Folder rootSourceFolder ) { } protected void runFolder ( Server s , Project p , View v , Type t , Folder f , File tgt ) { } protected void runItem ( Server s , Project p , View v , Type t , Folder f , Item item , File tgt ) { } protected boolean shouldCheckout ( String pName ) { } protected boolean matchPatterns ( String patterns , String pName ) { } protected Property getPrimaryDescriptor ( Type t ) { } protected Property getSecondaryDescriptor ( Type t ) { } protected String formatForDisplay ( Property p , Object value ) { } public void setServerName ( String serverName ) { } public String getServerName ( ) { } public void setServerPort ( int serverPort ) { } public int getServerPort ( ) { } public void setProjectName ( String projectName ) { } public String getProjectName ( ) { } public void setViewName ( String viewName ) { } public String getViewName ( ) { } public void setFolderName ( String folderName ) { } public String getFolderName ( ) { } public void setUsername ( String username ) { } public String getUsername ( ) { } public void setPassword ( String password ) { } public String getPassword ( ) { } public void setTargetFolder ( String targetFolder ) { } public String getTargetFolder ( ) { } public void setForce ( boolean force ) { } public boolean getForce ( ) { } public void setRecursion ( boolean recursion ) { } public boolean getRecursion ( ) { } public void setVerbose ( boolean verbose ) { } public boolean getVerbose ( ) { } public void setIncludes ( String includes ) { } public String getIncludes ( ) { } public void setExcludes ( String excludes ) { } public String getExcludes ( ) { } public boolean getTargetFolderAbsolute ( ) { } public void setTargetFolderAbsolute ( boolean targetFolderAbsolute ) { } }

Fix:
runType ( s , p , v , s . typeForName ( s . getTypeNames ( ) . FILE ) ) ;