.\" Generated by the Allegro makedoc utility .TH ustrdup 3alleg4 "version 4.4.3" "Allegro" "Allegro manual" .SH NAME ustrdup \- Duplicates a string. Allegro game programming library.\& .SH SYNOPSIS .B #include .sp .B char *ustrdup(const char *src) .SH DESCRIPTION This functions copies the null-terminated string `src' into a newly allocated area of memory, effectively duplicating it. Example: .nf void manipulate_string(const char *input_string) { char *temp_buffer = ustrdup(input_string); /* Now we can modify temp_buffer */ ... .fi .SH "RETURN VALUE" Returns the newly allocated string. This memory must be freed by the caller. Returns NULL if it cannot allocate space for the duplicated string. .SH SEE ALSO .BR _ustrdup (3alleg4), .BR uconvert (3alleg4), .BR ustrsize (3alleg4), .BR ustrsizez (3alleg4), .BR exconfig (3alleg4)