main
Dominik Madarász 2023-08-21 21:11:54 +02:00
parent 86e129e210
commit 36c7a81884
4 changed files with 25 additions and 25 deletions

View File

@ -338926,15 +338926,15 @@ char** server_poll(unsigned timeout_ms) {
}
else client_id = next_client_id++;
if (network_get(NETWORK_BUF_CLEAR_ON_JOIN)) {
array(netbuffer_t) *list = map_find(buffers, client_id);
// if (network_get(NETWORK_BUF_CLEAR_ON_JOIN)) {
// array(netbuffer_t) *list = map_find(buffers, client_id);
if (list)
for(int i = 0, end = array_count(list); i < end; ++i) {
netbuffer_t *nb = &list[i];
memset(nb->ptr, 0, nb->sz);
}
}
// if (list)
// for(int i = 0, end = array_count(list); i < end; ++i) {
// netbuffer_t *nb = &list[i];
// memset(nb->ptr, 0, nb->sz);
// }
// }
map_find_or_add(clients, event.peer, client_id);
map_find_or_add(peers, client_id, event.peer);

View File

@ -463,15 +463,15 @@ char** server_poll(unsigned timeout_ms) {
}
else client_id = next_client_id++;
if (network_get(NETWORK_BUF_CLEAR_ON_JOIN)) {
array(netbuffer_t) *list = map_find(buffers, client_id);
// if (network_get(NETWORK_BUF_CLEAR_ON_JOIN)) {
// array(netbuffer_t) *list = map_find(buffers, client_id);
if (list)
for(int i = 0, end = array_count(list); i < end; ++i) {
netbuffer_t *nb = &list[i];
memset(nb->ptr, 0, nb->sz);
}
}
// if (list)
// for(int i = 0, end = array_count(list); i < end; ++i) {
// netbuffer_t *nb = &list[i];
// memset(nb->ptr, 0, nb->sz);
// }
// }
map_find_or_add(clients, event.peer, client_id);
map_find_or_add(peers, client_id, event.peer);

View File

@ -9940,15 +9940,15 @@ char** server_poll(unsigned timeout_ms) {
}
else client_id = next_client_id++;
if (network_get(NETWORK_BUF_CLEAR_ON_JOIN)) {
array(netbuffer_t) *list = map_find(buffers, client_id);
// if (network_get(NETWORK_BUF_CLEAR_ON_JOIN)) {
// array(netbuffer_t) *list = map_find(buffers, client_id);
if (list)
for(int i = 0, end = array_count(list); i < end; ++i) {
netbuffer_t *nb = &list[i];
memset(nb->ptr, 0, nb->sz);
}
}
// if (list)
// for(int i = 0, end = array_count(list); i < end; ++i) {
// netbuffer_t *nb = &list[i];
// memset(nb->ptr, 0, nb->sz);
// }
// }
map_find_or_add(clients, event.peer, client_id);
map_find_or_add(peers, client_id, event.peer);

View File

@ -596,7 +596,7 @@ details > summary::-webkit-details-marker {
|Version: | 2023.7 |
|:--------------|:------------|
|Branch: | main |
|Commit: | 59 |
|Commit: | 60 |
<!--| Documentation last modified | { {LAST_MODIFIED} } |-->
# [V·4·K 2023.7 ](https://dev.v4.games/zaklaus/v4k)