Crash fixes and general stability improvements#123
Merged
Conversation
Force67
approved these changes
Apr 19, 2022
| create_directory(logPath, ec); | ||
|
|
||
| auto rotatingLogger = std::make_shared<spdlog::sinks::rotating_file_sink_mt>(logPath / "tp_client.log", 1048576 * 5, 3); | ||
| rotatingLogger->set_level(spdlog::level::debug); |
Member
There was a problem hiding this comment.
Make this off for stable builds?
Member
Author
There was a problem hiding this comment.
The rotatinglogger logs to file, not the console. I didn't fully complete it in this PR, but the goal is to somehow send these logs to Sentry on crash, if that's somehow possible.
Member
There was a problem hiding this comment.
Take a look at the sentry native documentation, it allows you to attach other files to crashes :)
Member
Author
There was a problem hiding this comment.
Ah, that'd be perfect, I'll do that in a follow up PR then 👍
Member
There was a problem hiding this comment.
This should be info at most in stable yea, apart from that I see no problem
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contains a bunch of fixes, some more questionable than others. The d3d11 check was removed because it was causing issues on amd gpus. Weapon draw state has been finalized. Unpaused some more menus.
Lastly, fixed a bug where the game would freeze when trying to loot worn items from a dead body. As you can see in the code, this fix in particular is quite questionable. The in game RemoveItem() function will lock the given ExtraDataList, and will only unlock that list when the hook returns. The thing is, we need to access the contents of that list, and therefore acquire a lock, but this obviously deadlocks. We can't "queue" the operation until later, since the lifetime of said ExtraDataList is not that long. The dirty fix I put in was not trying to acquire a lock in this particular hook through ScopedExtraDataOverride. If anyone has a better solution, I'd love to hear it.