-
Implicit casting uint8_t * to char *.
Here is an example, but there are more places where this is done.
|
i8_ret = cognit_http_send(ui8_payload, payload_len, &t_http_config); |
You can use -Wpointer-sign compilation flag
-
Function was supposed to be called, but no arguments (-Waddress):
Here:
and here:
|
if (is_requirement_upload_limit_reached) |
-
const qualifier is discarded in a few places (-Wdiscarded-qualifiers)
-
Value may be used uninitialized (-Wmaybe-uninitialized)
|
return (res == CURLE_OK) ? 0 : -1; |
but there is also some payload_len uninitialized.
In general, I would suggest compiling with more warnings (-Wall) and at least reading through all of them, as there may be some more issues then the ones I have listed here.
Implicit casting
uint8_t *tochar *.Here is an example, but there are more places where this is done.
device-runtime-c/cognit/src/cognit_frontend_cli.c
Line 56 in 1dbec5a
You can use
-Wpointer-signcompilation flagFunction was supposed to be called, but no arguments (
-Waddress):Here:
device-runtime-c/cognit/src/device_runtime_state_machine.c
Line 42 in 1dbec5a
and here:
device-runtime-c/cognit/src/device_runtime_state_machine.c
Line 63 in 1dbec5a
constqualifier is discarded in a few places (-Wdiscarded-qualifiers)Value may be used uninitialized (
-Wmaybe-uninitialized)device-runtime-c/examples/minimal-offload-sync-example.c
Line 198 in 1dbec5a
but there is also some
payload_lenuninitialized.In general, I would suggest compiling with more warnings (
-Wall) and at least reading through all of them, as there may be some more issues then the ones I have listed here.