fixed getMesh segfault and typo in shutdown()