Follow-up Comment #3, bug #62398 (project groff):
The "new" operator (with len = 0) creates a pointer that points to a
"NULL" (nullptr) in the memory.
This can be seen when output is inserted to the code, for example
if (len = 0) {
fprintf(stderr, "%s %s:%d allocated size = %d, base = %p; string = %s\n",
"warning:", __FILE__, __LINE__, len, base, s);
}
Thus this is a superfluous creation of pointers.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?62398>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/