We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
See LedgerHQ/nanox-secure-sdk#13
The text was updated successfully, but these errors were encountered:
@Ericson2314 in LedgerHQ/nanox-secure-sdk#13 your are proposing to change PIC macro to: #define PIC(x) ((typeof(x)) pic((void *)x)) Sadly this is raising issue on many apps. For example for app with code like: https://github.com/LedgerHQ/app-boilerplate/blob/c46ba042298e06bb7b168d375398fdb0cca51823/src/handler/get_app_name.c#L28-L34 This lead to build issue:
#define PIC(x) ((typeof(x)) pic((void *)x))
[CC] build/nanox/obj/get_app_name.o src/handler/get_app_name.c:32:42: error: used type 'typeof ("my_app")' (aka 'char [7]') where arithmetic or pointer type is required buffer_t rdata = {.ptr = (uint8_t *) PIC(MYAPPNAME), .size = APPNAME_LEN, .offset = 0}; ^~~~~~~~~~~~~~ /home/xchapron/Workspace/LedgerHQ/ledger-secure-sdk/include/os_pic.h:10:17: note: expanded from macro 'PIC' #define PIC(x) ((typeof(x)) pic((void *)x)) ^ ~~~~~~~~~~~~~~ 1 error generated.
This issue can be fixed by changing on app side: buffer_t rdata = {.ptr = (uint8_t *) PIC(APPNAME), .size = APPNAME_LEN, .offset = 0}; By: buffer_t rdata = {.ptr = (uint8_t *) PIC(&APPNAME[0]), .size = APPNAME_LEN, .offset = 0};
buffer_t rdata = {.ptr = (uint8_t *) PIC(APPNAME), .size = APPNAME_LEN, .offset = 0};
buffer_t rdata = {.ptr = (uint8_t *) PIC(&APPNAME[0]), .size = APPNAME_LEN, .offset = 0};
But requiring this is not really wanted.
Do you know another way to achieve this?
Sorry, something went wrong.
No branches or pull requests
See LedgerHQ/nanox-secure-sdk#13
The text was updated successfully, but these errors were encountered: