NoCatSplash bugs
Kristoffer Koch <[email protected]>
| Newsgroups | gmane.network.nocat |
|---|---|
| Message-ID | <[email protected]> |
It seems that NoCatSplash has a bug that crashes splashd when
repeatedly hitting the refresh button in the status page. Here is what
happens:
gettimeofday({946685898, 55875}, NULL) = 0
read(8, "GET /status HTTP/1.1\r\nHost: 192."..., 4096) = 479
time([946685898]) = 946685898
open("/etc/TZ", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/nocat/htdocs/status.html", O_RDONLY) = 9
fstat(9, {st_mode=S_IFREG|0644, st_size=1059, ...}) = 0
old_mmap(NULL, 1059, PROT_READ, MAP_SHARED, 9, 0) = 0x2aaae000
munmap(0x2aaae000, 1059) = 0
close(9) = 0
write(8, "HTTP/1.1 200 OK\r\nContent-Type: t"..., 44) = 44
write(8, "<html>\n<head><title>NoCat Gatewa"..., 1004) = -1 EPIPE (Broken pipe)
--- SIGPIPE (Broken pipe) @ 0 (0) ---
Process 1672 detached
[1] + Broken pipe splashd -D
I also think that the sockets dont get set to non-blocking, as the
splashd sometimes hangs while reading a client (browser) for header
data. It hangs until one hits stop in the browser (disconnects). At
the moment, I cant reproduce this bug, but I have observed it a couple
of times.
It might also be a good idea to use SO_REUSEADDR? (nice when it
crashes and has to be restarted, so that one dont have to wait
"forever")
I havent really looked at the source, but maybe someone here who knows
more about nocatsplash could fix this? (I dont write good C)
--
Kristoffer Koch
[email protected]
990 26 250