-
Notifications
You must be signed in to change notification settings - Fork 32
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
Compatibility additions #6
Compatibility additions #6
Conversation
Fixed a string error and switched to uint32_t
…dition Update bnkextr.cpp
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to include the C++ header cstdint
instead of the C header stdint.h
to get the std::
prefix.
bnkextr.cpp
Outdated
@@ -47,6 +47,8 @@ ENVS | |||
#include <fstream> | |||
#include <iostream> | |||
#include <vector> | |||
#include <string> | |||
#include <stdint.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you use <cstdint>
instead?
bnkextr.cpp
Outdated
@@ -56,14 +58,14 @@ struct Index | |||
{ | |||
int unknown; | |||
int offset; | |||
unsigned int size; | |||
uint32_t size; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd go with std::uint32_t
. Can you also use std::int32_t
for the two ints above?
bnkextr.cpp
Outdated
}; | ||
|
||
#pragma pack(push, 1) | ||
struct Section | ||
{ | ||
char sign[4]; | ||
unsigned int size; | ||
uint32_t size; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again std::
please 🙂
Added #include because the std's don't work without (no idea how it worked without the include on your end? But on my end it didn't work without it). And changed to uint32_t :)