Buggy code:
public class Shell implements Runnable { private class ShellThread extends Thread { private Command c ; public ShellThread ( Command c ) { } public void kill ( ) { } public Command getCommand ( ) { } } public static final String USER_NAME = System . getProperty ( "user.name" ) ; public static final File START_DIRECTORY = new File ( System . getProperty ( "user.home" ) ) ; public static final String NEW_LINE = System . getProperty ( "line.separator" ) ; private Interpreter interpreter ; private File currentDirectory ; private boolean error ; private final Pattern linePattern ; private Matcher m ; private Hashtable < Integer , Shell . ShellThread > backgroundProcesses ; private int processCount = 0 ; private boolean printUserDirectory ; public Shell ( ) { } public File getDirectory ( ) { } public void killCommand ( int pid ) { } public void printUserDirectory ( ) { } public void setDirectory ( File directory ) { } public void run ( ) { try { while ( true ) { Shell . ShellThread current = null ; error = false ; String input = readInput ( ) ; m = linePattern . matcher ( input ) ; printUserDirectory = false ; if ( m . matches ( ) ) { String [ ] args = parse ( input ) ; if ( args [ 0 ] . equals ( "kill" ) ) { try { int pid = Integer . parseInt ( args [ 1 ] ) ; killCommand ( pid ) ; } catch ( NumberFormatException e ) { showErrorMessage ( "Argument<seq2seq4repair_space>invalide<seq2seq4repair_space>pour<seq2seq4repair_space>la<seq2seq4repair_space>commande<seq2seq4repair_space>kill" ) ; } } else { String outputPath = m . group ( "outputPath" ) ; Command c ; if ( input . contains ( "|" ) ) c = new Pipe ( this , input . split ( "\\|" ) ) ; else c = interpreter . command ( args [ 0 ] , args [ 1 ] ) ; c . setOutputPath ( outputPath ) ; <START_BUG> boolean overwrite = m . group ( "overwrite" ) . equals ( ">" ) ; <END_BUG> c . setOverwrite ( overwrite ) ; if ( ( ! ( error ) ) && ( c != null ) ) { if ( ( input . endsWith ( "&" ) ) && ( c instanceof Backgroundable ) ) { current = new Shell . ShellThread ( c ) ; c . setPID ( ( ( processCount ) ++ ) ) ; ( ( Backgroundable ) ( c ) ) . setBackground ( true ) ; System . out . println ( ( ( ( ( args [ 0 ] ) + "<seq2seq4repair_space>pid=" ) + ( c . getPID ( ) ) ) + "<seq2seq4repair_space>commencé" ) ) ; backgroundProcesses . put ( c . getPID ( ) , current ) ; printUserDirectory ( ) ; current . start ( ) ; } else { c . run ( ) ; String result = c . result ( ) ; if ( ( outputPath == null ) || ( outputPath . equals ( "" ) ) ) { if ( result != null ) System . out . println ( result ) ; } else { writeOutput ( result , outputPath , overwrite ) ; } } } } } else showErrorMessage ( "Symbole<seq2seq4repair_space>illégale" ) ; if ( ( ! ( printUserDirectory ) ) && ( ( current == null ) || ( ! ( current . isAlive ( ) ) ) ) ) printUserDirectory ( ) ; } } catch ( Exception e ) { e . printStackTrace ( ) ; } } public void notifyFinished ( Command c , boolean error ) { } private boolean writeOutput ( String output , String path , boolean canOverwrite ) { } public String [ ] parse ( String input ) { } private String readInput ( ) { } public void showErrorMessage ( String message ) { } public static void main ( String [ ] args ) { } }

Fix:
boolean overwrite = ">" . equals ( m . group ( "overwrite" ) ) ;