Fix some errors of runtime