Merge "Fix some bugs for robustness." into rvc-dev