Closed chrstphrchvz closed 6 years ago
Thanks for the quick merge, however I hadn't yet checked RT for anything similar. It turns out these changes were part of a patch @jquelin submitted a few years ago: https://rt.cpan.org/Ticket/Display.html?id=78308. His patch includes some additional changes to Perl code Tcl.xs that might want to be added in , whereas I only updated XS code.
Correction: his patch was also only for Tcl.xs and not Perl code, just that it had other changes besides using croak("%s", …)
.
There were two other changes in his patch:
warn("%s", …)
, which has since been applied as part of 85681a436a907b85954f416377aaff829276dc96count
to int
when used in croak()
; this hasn't been applied already. Nor did my compiler (clang) warn me about this.
Currently, warnings like the following might be printed for Tcl.xs:
I added the
"%s"
format string to anycroak(Tcl_GetStringResult(interp))
statements (6 total) as suggested to prevent this warning.I'm not aware of any specific "risky" use cases, but I imagine that fixing would prevent legitimate Tcl output from being mistaken for a format string and resulting in "garbage" output.