Fixed compile errors for a stable version.