We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a28925a commit 3ef52adCopy full SHA for 3ef52ad
samples/net/ocpp/src/main.c
@@ -126,7 +126,7 @@ static int user_notify_cb(enum ocpp_notify_reason reason,
126
127
tid[idx] = k_thread_create(&tinfo[idx], cp_stk[idx],
128
sizeof(cp_stk[idx]), ocpp_cp_entry,
129
- (void *)(idx + 1), idtag[idx],
+ (void *)(uintptr_t)(idx + 1), idtag[idx],
130
obs[idx], 7, 0, K_NO_WAIT);
131
132
return 0;
@@ -148,7 +148,7 @@ static int user_notify_cb(enum ocpp_notify_reason reason,
148
static void ocpp_cp_entry(void *p1, void *p2, void *p3)
149
{
150
int ret;
151
- int idcon = (uint32_t)p1;
+ int idcon = (int)(uintptr_t)p1;
152
char *idtag = (char *)p2;
153
struct zbus_observer *obs = (struct zbus_observer *)p3;
154
ocpp_session_handle_t sh = NULL;
@@ -322,7 +322,7 @@ int main(void)
322
323
tid[i] = k_thread_create(&tinfo[i], cp_stk[i],
324
sizeof(cp_stk[i]),
325
- ocpp_cp_entry, (void *)(i + 1),
+ ocpp_cp_entry, (void *)(uintptr_t)(i + 1),
326
idtag[i], obs[i], 7, 0, K_NO_WAIT);
327
}
328
0 commit comments