patch for preventing some error.