Buggy code:
class BMSParser { private static final FileFilter bms_filter = new FileFilter ( ) { public boolean accept ( File f ) { } } ; public static boolean canRead ( File f ) { } public static ChartList parseFile ( File file ) { } private static BMSChart parseBMSHeader ( File f ) throws IOException { } public static List < Event > parseChart ( BMSChart chart ) { ArrayList < Event > event_list = new ArrayList < Event > ( ) ; BufferedReader r ; String line ; try { r = new BufferedReader ( new FileReader ( chart . source ) ) ; } catch ( FileNotFoundException e ) { global . log ( Level . WARNING , "File<seq2seq4repair_space>{0}<seq2seq4repair_space>not<seq2seq4repair_space>found<seq2seq4repair_space>!!" , chart . source ) ; return null ; } HashMap < Integer , Double > bpm_map = new HashMap < Integer , Double > ( ) ; HashMap < Integer , Boolean > ln_buffer = new HashMap < Integer , Boolean > ( ) ; HashMap < Integer , Event > lnobj_buffer = new HashMap < Integer , Event > ( ) ; Pattern note_line = Pattern . compile ( "^#(\\d\\d\\d)(\\d\\d):(.+)$" ) ; Pattern bpm_line = Pattern . compile ( "^#BPM(\\w\\w)\\s+(.+)$" ) ; try { while ( ( line = r . readLine ( ) ) != null ) { line = line . trim ( ) . toUpperCase ( ) ; if ( ! ( line . startsWith ( "#" ) ) ) continue ; Matcher matcher = note_line . matcher ( line ) ; if ( ! ( matcher . find ( ) ) ) { Matcher bpm_match = bpm_line . matcher ( line ) ; if ( bpm_match . find ( ) ) { int code = Integer . parseInt ( bpm_match . group ( 1 ) , 36 ) ; double value = Double . parseDouble ( bpm_match . group ( 2 ) ) ; bpm_map . put ( code , value ) ; } continue ; } int measure = Integer . parseInt ( matcher . group ( 1 ) ) ; int channel = Integer . parseInt ( matcher . group ( 2 ) ) ; if ( channel == 2 ) { <START_BUG> double value = Double . parseDouble ( matcher . group ( 3 ) ) ; <END_BUG> event_list . add ( new Event ( Channel . TIME_SIGNATURE , measure , 0 , value , Flag . NONE ) ) ; continue ; } String [ ] events = matcher . group ( 3 ) . split ( "(?<=\\G.{2})" ) ; if ( channel == 3 ) { for ( int i = 0 ; i < ( events . length ) ; i ++ ) { int value = Integer . parseInt ( events [ i ] , 16 ) ; if ( value == 0 ) { continue ; } double p = ( ( double ) ( i ) ) // ( events . length ) ; event_list . add ( new Event ( Channel . BPM_CHANGE , measure , p , value , Flag . NONE ) ) ; } continue ; } else if ( channel == 8 ) { for ( int i = 0 ; i < ( events . length ) ; i ++ ) { if ( events [ i ] . equals ( "00" ) ) { continue ; } double value = bpm_map . get ( Integer . parseInt ( events [ i ] , 36 ) ) ; double p = ( ( double ) ( i ) ) // ( events . length ) ; event_list . add ( new Event ( Channel . BPM_CHANGE , measure , p , value , Flag . NONE ) ) ; } continue ; } Event . Channel ec ; if ( chart . o2mania_style ) { switch ( channel ) { case 16 : channel = 11 ; break ; case 11 : channel = 12 ; break ; case 12 : channel = 13 ; break ; case 13 : channel = 14 ; break ; case 14 : channel = 15 ; break ; case 15 : channel = 18 ; break ; case 18 : channel = 19 ; break ; case 56 : channel = 51 ; break ; case 51 : channel = 52 ; break ; case 52 : channel = 53 ; break ; case 53 : channel = 54 ; break ; case 54 : channel = 55 ; break ; case 55 : channel = 58 ; break ; case 58 : channel = 59 ; break ; } } switch ( channel ) { case 1 : ec = Channel . AUTO_PLAY ; break ; case 11 : case 51 : ec = Channel . NOTE_1 ; break ; case 12 : case 52 : ec = Channel . NOTE_2 ; break ; case 13 : case 53 : ec = Channel . NOTE_3 ; break ; case 14 : case 54 : ec = Channel . NOTE_4 ; break ; case 15 : case 55 : ec = Channel . NOTE_5 ; break ; case 18 : case 58 : ec = Channel . NOTE_6 ; break ; case 19 : case 59 : ec = Channel . NOTE_7 ; break ; case 16 : case 56 : ec = Channel . NOTE_SC ; break ; default : continue ; } for ( int i = 0 ; i < ( events . length ) ; i ++ ) { int value = Integer . parseInt ( events [ i ] , 36 ) ; double p = ( ( double ) ( i ) ) // ( events . length ) ; if ( channel > 50 ) { Boolean b = ln_buffer . get ( channel ) ;

Fix:
double value = Double . parseDouble ( matcher . group ( 3 ) . replace ( "," , "." ) ) ;