Change addNewBorder to use safe_str() instead of strncat().