News for hackers. Stuff that matters.
Re:The Type of Sprintf by trealira on Tuesday May 14, 2024 @11:53PM (#40362930)
Yes, I was also confused at first.

The closest C function to this one is asprintf, because this function gives you back a new, separate string, which you may or may not decide to print. Just imagine if asprintf simply returned a char* pointing to an allocation by malloc, instead of taking an extra char ** as an out parameter.

  char *my_sprintf(const char *, ...);

There are no comments on this comment yet.