-
Notifications
You must be signed in to change notification settings - Fork 158
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
Fixed multiple warnings. #582
Open
vitimiti
wants to merge
18
commits into
HaxeFoundation:master
Choose a base branch
from
vitimiti:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+21
−16
Conversation
This file contains 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
Added the .vscode folder to be ignored.
Initialized the utf_chars array to an empty array.
Removed trailing whitespace after if clause.
Added a missing FILED_TYPE_JSON filed to the enum_field_types enumeration. Changed the magic numbers in the switch case 246 and 245 for FILED_TYPE_NEWDECIMAL and FILED_TYPE_JSON respectively.
Added a return logic to the HL_NAME function based on SDL. Added missing casts to the HL_NAME implementation using hl_copy_bytes.
Added explicit cast for the function sqlite3_prepare16_v2 which expects a const void** as 5th argument instead of the const char** that tl represents.
Added missing parenthesis to suppress different types size warnings. Added an if clause in hl_free to avoid running through null pointers.
Now addr type within hl_debug_read_register is vbyte* to prevent warnings in hl_debug_read in line 351.
Moved the "free(store);" line to after the "hl_remove_root(store);" line to prevent the use of a NULL pointer in hl_remove_root.
Added two ustrdup logic to prevent accidentally modifying the const uchar *str parameter. Copied this str to a local variable to modify said pointer locally and not modify str, as promised by the const identifier.
Now the send function is explicitly casted to int.
Now the integer is first cast into a long integer to make the cast to vbyte* be of equivalent size.
Aurel300
reviewed
Jan 31, 2023
Aurel300
reviewed
Jan 31, 2023
Now the variable does not have the same name as the C function. Removed unnecessary comments.
Aurel300
reviewed
Jan 31, 2023
Fixed second instance of using a C function name as a variable name. Improved the naming of the copied str.
Aurel300
reviewed
Jan 31, 2023
Reverted if statement to prevent breaking changes.
Explicitly added a 0 in the array initialization to prevent MSVC errors.
It looks like my C++ training got in the way of how to properly initialize arrays to all zeros. I have added the proper C way and I will see if the tests now pass in MSVC. |
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.
Added explicit casts and added some NULL pointer checks to remove warnings that happen during compilation and prevent undefined behaviour.