Buffer overflow corrected