Remove %w from snprintf compat code.

It's not part of the standard, we don't use it and rsync, from whence the
code originated, removed it in 2007 along with a bunch of other changes
Also fixes a potential out-of bounds read if (%w is used, which we don't).

Prompted by github PR#717.
This commit is contained in:
Darren Tucker committed 2026-10-11 20:52:59 +11:00
1 parent 4fdc4e8469
commit 73c1399eb4
1 file changed
-4
-4
View File
@@ -468,10 +468,6 @@ dopr(char *buffer, size_t maxlen, const char *format, va_list args_in)
case '%':
DOPR_OUTCH(buffer, currlen, maxlen, ch);
break;
case 'w':
/* not supported yet, treat as next char */
ch = *format++;
break;
default:
/* Unknown, skip */
break;