Improve resource management.