From mboxrd@z Thu Jan 1 00:00:00 1970 From: andrey mirtchovski To: 9fans@cse.psu.edu Message-ID: MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="-1618459641-303943946-1071847326=:13780" Subject: [9fans] Forwarded attachment... Date: Fri, 19 Dec 2003 08:22:06 -0700 Topicbox-Message-UUID: ac9fb48e-eacc-11e9-9e20-41e7f4b1d025 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. Send mail to mime@docserver.cac.washington.edu for more info. ---1618459641-303943946-1071847326=:13780 Content-Type: TEXT/PLAIN; charset=US-ASCII This patch fixes links crashing terminals. I lost all my work from yesterday so I couldn't get it on the web. The problem isn't so bad if you have more memory (>= 512 with untouched kernelpercent) where only links will crash. that's why we were able to debug it yesterday... andrey ---1618459641-303943946-1071847326=:13780 Content-Type: TEXT/PLAIN; CHARSET=US-ASCII Content-ID: Content-Description: I don't know whether that's the same bug, but links crashed on nikkei.com due to a memcpy() being called with a nil second argument in dns.c:49. I've worked around it as follows: diff /n/dump/2003/1218/usr/andrey/src/links-ape/dns.c /usr/andrey/src/links-ape/dns.c 47,48c47,49 < nogethostbyaddr: if (!(hst = gethostbyname((char *)name))) < return -1; --- > nogethostbyaddr: > if (!(hst = gethostbyname((char *)name)) || !hst->h_addr_list[0]) > return -1; also add this one: diff /n/dump/2003/1218/usr/andrey/src/links-ape/config.h /usr/andrey/src/links-ape/config.h 22a23 > #define HAVE_GETHOSTBYADDR 1 Can you verify if this fixes links' crashing? The problem with nikkei not displaying proper fonts is because they're using Shift_GIS encoding, which Links doesn't know how to handle. I should port lunix' "iconv" which knows everything there is to know about encodings, and will make links use that instead of its own (limited) conversion tables, then it'll handle Shift_JIS and many more sites as it should. That won't happen immediately, though... andrey ---1618459641-303943946-1071847326=:13780--