Skip to content
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

Update dependencies, Bug fixes, OS detection #63

Merged
merged 52 commits into from
Apr 30, 2022
Merged

Update dependencies, Bug fixes, OS detection #63

merged 52 commits into from
Apr 30, 2022

Conversation

lcsmuller
Copy link
Collaborator

@lcsmuller lcsmuller commented Apr 29, 2022

What?

  1. Replace uthash.h with chash.h and update jsmn-find version - See Update dependencies #62
  2. Detect client OS - See 404d0a0
  3. Bug Fixes
    3.1. Regression where logconf.c logging modules couldn't be disabled, therefore making config.json disable_modules field useless.
    3.2. Uninitialized fields at application_command.c - See a2d89b2
    3.3. Timer passing ID 0 - See Timer Get Function Fix #64

Why?

  1. See Update dependencies #62 for description
  2. For Discord identification purposes, the previous behavior of defaulting to "POSIX" is a simplification that may end-up becoming a inaccuracy as we support more systems in the future.
  3. Bug Fixes
    3.1. Users reportedly were unable to use discord_config_init() on some builds (Android) due to a logconf.c regression where a struct logconf module and its sub-modules would each attempt to handle their log_Logger * uniquely, when in reality the same log_Logger* is shared amongst them all.
    3.2. Would lead to a segfault at best, or access memory garbage at worst.
    3.3. See Timer Get Function Fix #64 for description

How?

  1. See Update dependencies #62 for description
  2. @HackerSmacker implementation's of osname.h, relying on the pre-processor to detect and assign the OS to a OSNAME macro.
  3. Bug Fixes
    3.1. Add a is_disabled boolean field to struct logconf, if enabled for a particular module then it shall be ignored for outputting.
    3.2. Initialize struct discord_request necessary for handling the preliminary Client to Discord request context
    3.3. See Timer Get Function Fix #64 for description

Testing?

  1. See Update dependencies #62 for description
  2. Run under different OSes and check the output http.log for Discord Gateway's IDENTIFY payload.
  3. Bug Fixes
    3.1. Test discord_config_init() under valgrind for OOB detection.
    3.2. Test under valgrind for OOB detection.

lcsmuller and others added 30 commits April 17, 2022 01:49
@lcsmuller lcsmuller added bug Something isn't working enhancement New feature or request labels Apr 29, 2022
@lcsmuller lcsmuller merged commit dd0d558 into master Apr 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants