libusb-win32
libusb-win32 copied to clipboard
Fix potentially insecure use of format strings
install-filter can change wait_string, so it may insecure.
One notable thing is that puts() outputs '\n' at the end of line, do you think it is good?
Can't you just do printf("%s", filter_context->wait_string); ?
Can't you just do
printf("%s", filter_context->wait_string);?
I'm sorry for my late reply. The reason why I use fputs() is it is more efficient than printf().
Additionally, I think there should be a better implementation here which don't pause that stdin is directed to a file (same as the pause in cmd.exe), so please don't merge this PR. Do you think it is useful? If so, I will submit a better implementation some days later.