Buggy code:
public class BRouterView extends View { RoutingEngine cr ; private int imgw ; private int imgh ; private int centerLon ; private int centerLat ; private double scaleLon ; private double scaleLat ; private List < OsmNodeNamed > wpList ; private List < OsmNodeNamed > nogoList ; private List < OsmNodeNamed > nogoVetoList ; private OsmTrack rawTrack ; private String modesDir ; private String tracksDir ; private String segmentDir ; private String profileDir ; private String profilePath ; private String profileName ; private String sourceHint ; private boolean waitingForSelection = false ; private boolean needsViaSelection ; private boolean needsNogoSelection ; private boolean needsWaypointSelection ; private long lastDataTime = System . currentTimeMillis ( ) ; private CoordinateReader cor ; private int [ ] imgPixels ; public void startSimulation ( ) { } public void stopSimulation ( ) { } public BRouterView ( Context context ) { } public void startSetup ( String baseDir , boolean storeBasedir ) { } public void continueProcessing ( ) { } public void updateViaList ( Set < String > selectedVias ) { } public void updateNogoList ( boolean [ ] enabled ) { } public void pickWaypoints ( ) { } public void updateWaypointList ( String waypoint ) { } public void finishWaypointSelection ( ) { } public void startProcessing ( String profile ) { } private void assertDirectoryExists ( String message , String path , String assetZip ) { } private void paintPosition ( int ilon , int ilat , int color , int with ) { } private void paintCircle ( Canvas canvas , OsmNodeNamed n , int color , int minradius ) { } @ Override protected void onSizeChanged ( int w , int h , int oldw , int oldh ) { } private void toast ( String msg ) { } private long lastTs = System . currentTimeMillis ( ) ; private long startTime = 0L ; @ Override protected void onDraw ( Canvas canvas ) { } private void _onDraw ( Canvas canvas ) { } private String guessBaseDir ( ) { } public void writeRawTrackToMode ( String mode ) { } public void startConfigureService ( ) { } public void configureService ( String [ ] routingModes , boolean [ ] checkedModes ) { } private String readSingleLineFile ( File f ) { } private static List < String > getStorageDirectories ( ) { ArrayList < String > res = new ArrayList < String > ( ) ; res . add ( Environment . getExternalStorageDirectory ( ) . getPath ( ) ) ; BufferedReader br = null ; try { br = new BufferedReader ( new FileReader ( "//proc//mounts" ) ) ; for ( ; ; ) { String line = br . readLine ( ) ; if ( line == null ) break ; if ( ( ( line . indexOf ( "vfat" ) ) < 0 ) && ( ( line . indexOf ( "//mnt" ) ) < 0 ) ) continue ; StringTokenizer tokens = new StringTokenizer ( line , "<seq2seq4repair_space>" ) ; tokens . nextToken ( ) ; String d = tokens . nextToken ( ) ; boolean isExternalDir = false ; if ( line . contains ( "//dev//block//vold" ) ) { isExternalDir = true ; <START_BUG> String [ ] vetos = new String [ ] { "//mnt//secure" , "//mnt//asec" , "//mnt//obb" , "//dev//mapper" , "tmpfs" } ; <END_BUG> for ( String v : vetos ) { if ( ( d . indexOf ( v ) ) >= 0 ) { isExternalDir = false ; } } } if ( isExternalDir ) { if ( ! ( res . contains ( d ) ) ) { res . add ( d ) ; } } } } catch ( Exception e ) { } finally { if ( br != null ) { try { br . close ( ) ; } catch ( Exception e ) { } } } return res ; } }

Fix:
String [ ] vetos = new String [ ] { "//mnt//secure" , "//mnt//asec" , "//mnt//obb" , "//dev//mapper" , "tmpfs" , "//mnt//media_rw" } ;