-
-
Notifications
You must be signed in to change notification settings - Fork 493
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix windows crash viewer #2987
Fix windows crash viewer #2987
Conversation
finally! |
wtfreaky |
…ertux into windows-crash-view2
@tobbi How can I ignore the cppcheck errors? |
Can you not simply fix them? Add a check for the path being empty? |
I still need to pass |
I think it can still be empty |
The contents of the string are empty but the size isn't. path[0] would probably just give a null character |
14:20:39] Tobbi: If I have an std::string and call reserve on it, can &path[0] still be out of bounds if the string itself is empty |
Alright then how do I check if the string is invalid before passing it into GetModuleFileName (the function that fills the string)? |
Just check the length: https://cplusplus.com/reference/string/string/length/ |
If GetModuleFileName fills the string then won't checking for the length of the string always reach the same result? |
Just check whether it's greater than 0, to silence the warning. |
No description provided.