Fix sereval problems