Problem: Valgrind reports using uninitialzed memory. (Dominique Pelle)
Solution: Check the length before checking for a NUL.
if (!(silent_mode && p_verbose == 0))
mch_settmode(TMODE_COOK); /* handle '\r' and '\n' correctly */
#endif
- while (*s != NUL && (maxlen < 0 || (int)(s - str) < maxlen))
+ while ((maxlen < 0 || (int)(s - str) < maxlen) && *s != NUL)
{
if (!(silent_mode && p_verbose == 0))
{
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 2349,
/**/
2348,
/**/