On Monday 21 January 2008, Thomas Heiligenmann wrote: > A new version of the plugin is available: > > Download: http://www.heiligenmann.de/vdr/download/ > Filename: vdr-wapd-0.9.tgz > Filesize: 31975 > > See HISTORY and README for details. Thanks to all, who have provided > ideas and patches. Here are some small patches for the next version: - i18n: fixes some missing translatable strings, adds missing/improves existing Finnish translations - headers: adds missing HTTP headers to the "access denied" response - signedness: fixes (un)signedness of source port format conversion in "connect from" log message - ntohs returns an uint16_t
diff -up wapd-0.9/access.c~ wapd-0.9/access.c --- wapd-0.9/access.c~ 2008-01-13 14:41:21.000000000 +0200 +++ wapd-0.9/access.c 2008-01-22 00:16:13.000000000 +0200 @@ -212,7 +212,11 @@ int cWapSocket::Accept(void) if (newsock > 0) { bool accepted = WapHosts.Acceptable(clientname.sin_addr.s_addr); if (!accepted) { - const char *s = "Access denied!\n"; + const char *s = + "HTTP/1.0 403 Forbidden\n" + "Server: VDR WAPD\n" + "Content-Type: text/plain\n\n" + "Access denied!\n"; write(newsock, s, strlen(s)); close(newsock); newsock = -1;
diff -up wapd-0.9/i18n.c~ wapd-0.9/i18n.c --- wapd-0.9/i18n.c~ 2008-01-15 10:27:29.000000000 +0200 +++ wapd-0.9/i18n.c 2008-01-22 00:30:12.000000000 +0200 @@ -140,7 +140,7 @@ const tI18nPhrase Phrases[] = { "", "Pas de résumé defini.", "", - "Yhteenvetoa ei saatavilla.", + "Kuvausta ei saatavilla.", "", "", "", @@ -497,7 +497,7 @@ const tI18nPhrase Phrases[] = { "", "Image", "", - "", + "Kuva", "", "", "", @@ -518,7 +518,7 @@ const tI18nPhrase Phrases[] = { "", "Pas de image disponible.", "", - "", + "Kuva ei saatavilla.", "", "", "", @@ -539,7 +539,7 @@ const tI18nPhrase Phrases[] = { "", "Image trop grand.", "", - "", + "Kuvan koko on liian suuri.", "", "", "", diff -up wapd-0.9/server.c~ wapd-0.9/server.c --- wapd-0.9/server.c~ 2008-01-19 16:41:46.000000000 +0200 +++ wapd-0.9/server.c 2008-01-22 00:30:39.000000000 +0200 @@ -963,9 +963,9 @@ void cWapServer::PageGrabImage(void) FlushBuffer(size); return; } else - ReplyBuffer("Image size too big."); + ReplyBuffer(wmltr("Image size too big.")); } else - ReplyBuffer("No image available."); + ReplyBuffer(wmltr("No image available.")); ReplyBuffer(WML_A_KEY("", URI_MAIN, "0", "%s") " ", wmltr("VDR")); ReplyBuffer(WML_END()); Header(200, "OK", MIME_TYPE, SERVER_NAME);
diff -up wapd-0.9/access.c~ wapd-0.9/access.c --- wapd-0.9/access.c~ 2008-01-13 14:41:21.000000000 +0200 +++ wapd-0.9/access.c 2008-01-22 00:14:46.000000000 +0200 @@ -217,7 +217,7 @@ int cWapSocket::Accept(void) close(newsock); newsock = -1; } - isyslog("WAPD: connect from %s, port %hd - %s", inet_ntoa(clientname.sin_addr), ntohs(clientname.sin_port), accepted ? "accepted" : "DENIED"); + isyslog("WAPD: connect from %s, port %hu - %s", inet_ntoa(clientname.sin_addr), ntohs(clientname.sin_port), accepted ? "accepted" : "DENIED"); } else if (errno != EINTR && errno != EAGAIN) LOG_ERROR; return newsock;
_______________________________________________ vdr mailing list vdr@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr