Buggy code:
, new int [ ] { 101 , SWT . F9 } , new int [ ] { 109 , SWT . F10 } , new int [ ] { 103 , SWT . F11 } , new int [ ] { 111 , SWT . F12 } , new int [ ] { 105 , SWT . F13 } , new int [ ] { 107 , SWT . F14 } , new int [ ] { 113 , SWT . F15 } , new int [ ] { 106 , SWT . F16 } , new int [ ] { 64 , SWT . F17 } , new int [ ] { 79 , SWT . F18 } , new int [ ] { 80 , SWT . F19 } , new int [ ] { 67 , SWT . KEYPAD_MULTIPLY } , new int [ ] { 69 , SWT . KEYPAD_ADD } , new int [ ] { 76 , SWT . KEYPAD_CR } , new int [ ] { 78 , SWT . KEYPAD_SUBTRACT } , new int [ ] { 65 , SWT . KEYPAD_DECIMAL } , new int [ ] { 75 , SWT . KEYPAD_DIVIDE } , new int [ ] { 82 , SWT . KEYPAD_0 } , new int [ ] { 83 , SWT . KEYPAD_1 } , new int [ ] { 84 , SWT . KEYPAD_2 } , new int [ ] { 85 , SWT . KEYPAD_3 } , new int [ ] { 86 , SWT . KEYPAD_4 } , new int [ ] { 87 , SWT . KEYPAD_5 } , new int [ ] { 88 , SWT . KEYPAD_6 } , new int [ ] { 89 , SWT . KEYPAD_7 } , new int [ ] { 91 , SWT . KEYPAD_8 } , new int [ ] { 92 , SWT . KEYPAD_9 } , new int [ ] { 81 , SWT . KEYPAD_EQUAL } , new int [ ] { 57 , SWT . CAPS_LOCK } , new int [ ] { 71 , SWT . NUM_LOCK } , new int [ ] { 114 , SWT . HELP } } ; static String APP_NAME ; static final String ADD_WIDGET_KEY = "org.eclipse.swt.internal.addWidget" ; static final byte [ ] SWT_OBJECT = new byte [ ] { 'S' , 'W' , 'T' , '_' , 'O' , 'B' , 'J' , 'E' , 'C' , 'T' , '' } ; static final byte [ ] SWT_IMAGE = new byte [ ] { 'S' , 'W' , 'T' , '_' , 'I' , 'M' , 'A' , 'G' , 'E' , '' } ; static final byte [ ] SWT_ROW = new byte [ ] { 'S' , 'W' , 'T' , '_' , 'R' , 'O' , 'W' , '' } ; static final byte [ ] SWT_COLUMN = new byte [ ] { 'S' , 'W' , 'T' , '_' , 'C' , 'O' , 'L' , 'U' , 'M' , 'N' , '' } ; static final String SET_MODAL_DIALOG = "org.eclipse.swt.internal.modalDialog" ; static Display Default ; static Display [ ] Displays = new Display [ 4 ] ; static final int GROW_SIZE = 1024 ; Widget [ ] skinList = new Widget [ Display . GROW_SIZE ] ; int skinCount ; static final String PACKAGE_PREFIX = "org.eclipse.swt.widgets." ; Runnable [ ] timerList ; NSTimer [ ] nsTimers ; SWTWindowDelegate timerDelegate ; static SWTApplicationDelegate applicationDelegate ; boolean runSettings ; SWTWindowDelegate settingsDelegate ; static final int DEFAULT_BUTTON_INTERVAL = 30 ; Object data ; String [ ] keys ; Object [ ] values ; static void setDevice ( Device device ) { } static byte [ ] ascii ( String name ) { } static int translateKey ( int key ) { } static int untranslateKey ( int key ) { } void addContext ( GCData context ) { if ( ( contexts ) == null ) contexts = new GCData [ 12 ] ; for ( int i = 0 ; i < ( contexts . length ) ; i ++ ) { <START_BUG> if ( ( ( contexts [ i ] ) != null ) || ( ( contexts [ i ] ) == context ) ) { <END_BUG> contexts [ i ] = context ; return ; } } GCData [ ] newContexts = new GCData [ ( contexts . length ) + 12 ] ; newContexts [ contexts . length ] = context ; System . arraycopy ( contexts , 0 , newContexts , 0 , contexts . length ) ; contexts = newContexts ; } public void addFilter ( int eventType , Listener listener ) { } void addLayoutDeferred ( Composite comp ) { } public void addListener ( int eventType , Listener listener ) { } void addMenu ( Menu menu ) { } void addPool ( ) { } void addPool ( NSAutoreleasePool pool ) { } void addPopup ( Menu menu ) { } void addSkinnableWidget ( Widget widget ) { } void addWidget ( NSObject view , Widget widget ) { } public void asyncExec ( Runnable runnable ) { } public void beep ( ) { } void cascadeWindow ( NSWindow window , NSScreen screen ) { } protected void checkDevice ( ) { } void checkEnterExit ( Control control , NSEvent nsEvent , boolean send ) { } void checkFocus ( ) { } protected void checkSubclass ( ) { } public Display ( ) { } public Display ( DeviceData data ) { } static void checkDisplay ( Thread thread , boolean multiple ) { } static NSRect convertRect ( NSScreen screen , NSRect frame ) { } static String convertToLf ( String text ) { } void clearModal ( Shell shell ) { } void clearPool ( ) { } public void close ( ) { } protected void create ( DeviceData data ) { }

Fix:
if ( ( ( contexts [ i ] ) == null ) || ( ( contexts [ i ] ) == context ) ) {