Patches item #1836228, was opened at 2007-11-22 05:37 Message generated for change (Settings changed) made by zmoelnig You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=478072&aid=1836228...
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: puredata
Group: None
Status: Open Resolution: None Priority: 5 Private: No Submitted By: Russell Bryant (russellbryant) Assigned to: Miller Puckette (millerpuckette) Summary: [patch] simplify pd_makeversion() in src/s_main.c
Initial Comment: This minor patch simplifies the pd_makeversion() function in src/s_main.c.
It replaces the sprintf / malloc / strcpy, with the equivalent single call to asprintf. It also provides the side benefit of removing the length limitation introduced by the intermediary stack buffer (with bounds that weren't being checked).
----------------------------------------------------------------------
Comment By: Hans-Christoph Steiner (eighthave) Date: 2007-11-23 20:24
Message: Logged In: YES user_id=27104 Originator: NO
Funny, I originally submitted the patch with this function and it included asprintf(). Miller accepted the patch, but replaced the asprintf() with the sprintf/malloc/strcpy combo, with only this comment:
"modified to avoid the effete asprintf() call, then took for 0.40"
----------------------------------------------------------------------
You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=478072&aid=1836228...