question: private static int [ ] WindowsRegCreateKeyEx1 ( int hKey , byte [ ] subKey ) { int [ ] result = WindowsRegCreateKeyEx ( hKey , subKey ) ; if ( result [ ERROR_CODE ] == ERROR_SUCCESS ) { return result ; } else { long sleepTime = INIT_SLEEP_TIME ; for ( int i = 0 ; i < MAX_ATTEMPTS ; i ++ ) { try { Thread . sleep ( sleepTime ) ; } catch ( InterruptedException e ) { return result ; } sleepTime *= 2 ; result = WindowsRegCreateKeyEx ( hKey , subKey ) ; if ( result [ ERROR_CODE ] == ERROR_SUCCESS ) { return result ; } } } return result ; }
target:  Retries RegCreateKeyEx() MAX_ATTEMPTS times before giving up.