fix more bugs in rand processes