Fixed Linux compatibility issues.