Production of n-rich nuclei in red giant stars