Buggy code:
public class TreeItem extends Item { Tree parent ; Font font ; Font [ ] cellFont ; boolean cached ; boolean grayed ; static final int EXPANDER_EXTRA_PADDING = 4 ; public TreeItem ( Tree parent , int style ) { } public TreeItem ( Tree parent , int style , int index ) { } public TreeItem ( TreeItem parentItem , int style ) { } public TreeItem ( TreeItem parentItem , int style , int index ) { } TreeItem ( Tree parent , int parentIter , int style , int index , boolean create ) { } static int checkIndex ( int index ) { } static TreeItem checkNull ( TreeItem item ) { } static Tree checkNull ( Tree control ) { } protected void checkSubclass ( ) { } void clear ( ) { } public void clear ( int index , boolean all ) { } public void clearAll ( boolean all ) { } void destroyWidget ( ) { } public Color getBackground ( ) { } public Color getBackground ( int index ) { } public Rectangle getBounds ( int index ) { } public Rectangle getBounds ( ) { } public boolean getChecked ( ) { } public boolean getExpanded ( ) { } public Font getFont ( ) { } public Font getFont ( int index ) { } public Color getForeground ( ) { } public Color getForeground ( int index ) { } public boolean getGrayed ( ) { } public Image getImage ( ) { } public Image getImage ( int index ) { } public Rectangle getImageBounds ( int index ) { } public int getItemCount ( ) { } public TreeItem getItem ( int index ) { } public TreeItem [ ] getItems ( ) { } String getNameText ( ) { } public Tree getParent ( ) { } public TreeItem getParentItem ( ) { } public String getText ( ) { } public String getText ( int index ) { } public int indexOf ( TreeItem item ) { } void redraw ( ) { } void releaseChildren ( boolean destroy ) { } void releaseHandle ( ) { } void releaseWidget ( ) { } public void removeAll ( ) { } public void setBackground ( Color color ) { } public void setBackground ( int index , Color color ) { } public void setChecked ( boolean checked ) { } public void setExpanded ( boolean expanded ) { } public void setFont ( Font font ) { } public void setFont ( int index , Font font ) { } public void setForeground ( Color color ) { } public void setForeground ( int index , Color color ) { } public void setGrayed ( boolean grayed ) { } public void setImage ( int index , Image image ) { checkWidget ( ) ; if ( ( image != null ) && ( image . isDisposed ( ) ) ) { error ( ERROR_INVALID_ARGUMENT ) ; } int count = Math . max ( 1 , parent . getColumnCount ( ) ) ; if ( ( 0 > index ) || ( index > ( count - 1 ) ) ) return ; int pixbuf = 0 ; if ( image != null ) { ImageList imageList = parent . imageList ; if ( imageList == null ) imageList = parent . imageList = new ImageList ( ) ; int imageIndex = imageList . indexOf ( image ) ; if ( imageIndex == ( - 1 ) ) imageIndex = imageList . add ( image ) ; pixbuf = imageList . getPixbuf ( imageIndex ) ; } int modelIndex = ( ( parent . columnCount ) == 0 ) ? Tree . FIRST_COLUMN : parent . columns [ index ] . modelIndex ; OS . gtk_tree_store_set ( parent . modelHandle , handle , ( modelIndex + ( Tree . CELL_PIXBUF ) ) , pixbuf , ( - 1 ) ) ; if ( ( ( parent . style ) & ( SWT . VIRTUAL ) ) != 0 ) { if ( ( ( OS . GTK_VERSION ) >= ( OS . VERSION ( 2 , 3 , 2 ) ) ) && ( ( OS . GTK_VERSION ) < ( OS . VERSION ( 2 , 6 , 3 ) ) ) ) { if ( ( parent . columnCount ) == 0 ) { redraw ( ) ; } } } <START_BUG> if ( ( ( parent . style ) & ( SWT . VIRTUAL ) ) != 0 ) { <END_BUG> if ( ( OS . GTK_VERSION ) >= ( OS . VERSION ( 2 , 3 , 2 ) ) ) { if ( image != null ) { int parentHandle = parent . handle ; int column = OS . gtk_tree_view_get_column ( parentHandle , index ) ; int [ ] w = new int [ 1 ] ; int pixbufRenderer = parent . getPixbufRenderer ( column ) ; OS . gtk_tree_view_column_cell_get_position ( column , pixbufRenderer , null , w ) ; if ( ( w [ 0 ] ) < ( image . getBounds ( ) . width ) ) { int style = OS . gtk_widget_get_modifier_style ( parentHandle ) ; OS . gtk_widget_modify_style ( parentHandle , style ) ; } } } } cached = true ; } public void setImage ( Image image ) { } public void setImage ( Image [ ] images ) { } public void setItemCount ( int count ) { } public void setText ( int index , String string ) { } public void setText ( String string ) { } public void setText ( String [ ] strings ) { } }

Fix:
if ( ( ( ( parent . style ) & ( SWT . VIRTUAL ) ) != 0 ) && ( ( parent . currentItem ) == null ) ) {