Ah shit, I think this is a known problem when you try to host an Iceball server on Windows. I don't know what actually causes it. The messagte shows up when common.udp_recvfrom() returns false.
From src/lua_udp.h:
Code: Select all socklen_t sadlen = sizeof(saddr);
n = recvfrom(sockfd, buf, sizeof(buf) - 1, 0, (struct sockaddr *)&saddr, &sadlen);
if (n == -1) {
#ifdef WIN32
int err = WSAGetLastError();
if (err != WSAEWOULDBLOCK) {
#else
int err = errno;
if (err != EAGAIN && err != EWOULDBLOCK) {
#endif
lua_pushboolean(L, 0);
return 1;
#ifdef WIN32
} else if (err == WSAEWOULDBLOCK) {
#else
} else if (err == EWOULDBLOCK || err == EAGAIN) {
#endif
lua_pushstring(L, "");
return 1;
}
}
After preprocessing:
Code: Select all socklen_t sadlen = sizeof(saddr);
n = recvfrom(sockfd, buf, sizeof(buf) - 1, 0, (struct sockaddr *)&saddr, &sadlen);
if (n == -1) {
int err = WSAGetLastError();
if (err != WSAEWOULDBLOCK) {
lua_pushboolean(L, 0);
return 1; // Lua gets: false
} else if (err == WSAEWOULDBLOCK) {
lua_pushstring(L, "");
return 1; // Lua gets: ""
}
}
Workaround to try:
Here's the code in pkg/base/lib_heartbeat.lua:
Code: Select all -- check if we received any messages
while true do
local msg, host, port = common.udp_recvfrom(heartbeat_sockfd)
if msg == "" then
break
elseif msg == false then
print("*** UDP socket used to connect to master servers broke horribly. What the hell?!")
irc.write("*** UDP socket used to connect to master servers broke horribly. What the hell?!")
heartbeat_t_burstsleft = nil
heartbeat_t_nextmsg = nil
Change it to this and see if it works:
Code: Select all -- check if we received any messages
while true do
local msg, host, port = common.udp_recvfrom(heartbeat_sockfd)
if msg == "" or msg == false then
break
You'll want to open it in an editor that doesn't shit itself when you give it a file with unix newlines - try wordpad instead of notepad.
I've got a feeling that this was tried and it didn't work, but if it somehow works... well, I guess that fixes *one* thing. Badly, though, but it'll do for a workaround while we find out how to fix the *real* issue.