about summary refs log tree commit diff stats
path: root/WWW/Library/Implementation
diff options
context:
space:
mode:
authorThomas E. Dickey <dickey@invisible-island.net>2001-10-06 22:20:25 -0400
committerThomas E. Dickey <dickey@invisible-island.net>2001-10-06 22:20:25 -0400
commitf78e27712a4f44dbdf3c1532c3d1958989bf40a5 (patch)
tree51a8f8acd39f65da307ae05a0b9276490e03bedd /WWW/Library/Implementation
parentfc99820d832c512631aa418520f5bc6a204e8b91 (diff)
downloadlynx-snapshots-f78e27712a4f44dbdf3c1532c3d1958989bf40a5.tar.gz
snapshot of project "lynx", label v2-8-5dev_3
Diffstat (limited to 'WWW/Library/Implementation')
-rw-r--r--WWW/Library/Implementation/HTDOS.c14
-rw-r--r--WWW/Library/Implementation/HTFTP.c7
-rw-r--r--WWW/Library/Implementation/HTTCP.c4
-rw-r--r--WWW/Library/Implementation/HTTP.c10
-rw-r--r--WWW/Library/Implementation/HTUtils.h1
5 files changed, 33 insertions, 3 deletions
diff --git a/WWW/Library/Implementation/HTDOS.c b/WWW/Library/Implementation/HTDOS.c
index 5313f1e5..0d943a25 100644
--- a/WWW/Library/Implementation/HTDOS.c
+++ b/WWW/Library/Implementation/HTDOS.c
@@ -67,8 +67,10 @@ char * HTDOS_wwwName ARGS1(CONST char *, dosname)
     if (wwwname_len > 1)
 	cp_url--;	/* point last char */
 
-    if (wwwname_len > 3 && *cp_url == '/')
+    if (wwwname_len > 3 && *cp_url == '/') {
+	cp_url++;
 	*cp_url = '\0';
+    }
 
 #ifdef NOTUSED
     if(*cp_url == ':') {
@@ -99,6 +101,16 @@ char * HTDOS_name ARGS1(char *, wwwname)
     int joe;
 
     copy_plus(&result, wwwname);
+#ifdef __DJGPP__
+    if (result[0] == '/'
+     && result[1] == 'd'
+     && result[2] == 'e'
+     && result[3] == 'v'
+     && result[4] == '/'
+     && isalpha(result[5])) {
+	return(result);
+    }
+#endif /* __DJGPP__ */
 
     for (joe = 0; result[joe] != '\0'; joe++)	{
 	if (result[joe] == '/')	{
diff --git a/WWW/Library/Implementation/HTFTP.c b/WWW/Library/Implementation/HTFTP.c
index 8cd3099c..4f279fab 100644
--- a/WWW/Library/Implementation/HTFTP.c
+++ b/WWW/Library/Implementation/HTFTP.c
@@ -363,6 +363,7 @@ PRIVATE char *help_message_cache_non_empty NOARGS
 {
   return(help_message_buffer);
 }
+
 PRIVATE char *help_message_cache_contents NOARGS
 {
    return(help_message_buffer);
@@ -795,8 +796,8 @@ PRIVATE int get_connection ARGS2(
 	return status;			/* Bad return */
     }
 
-    CTRACE((tfp, "FTP connected, socket %d  control %ld\n",
-		con->socket, (long)con));
+    CTRACE((tfp, "FTP connected, socket %d  control %p\n",
+		con->socket, con));
     control = con;		/* Current control connection */
 
     /* Initialise buffering for control connection */
@@ -2936,6 +2937,8 @@ PUBLIC int HTFTPLoad ARGS4(
 				   get to the point of reading data - kw */
     HTFormat format;
 
+    CTRACE((tfp, "HTFTPLoad(%s) %s connection\n", name, ftp_passive ? "passive" : "normal"));
+
     /* set use_list to NOT since we don't know what kind of server
      * this is yet.  And set the type to GENERIC
      */
diff --git a/WWW/Library/Implementation/HTTCP.c b/WWW/Library/Implementation/HTTCP.c
index fd916955..6660ee4a 100644
--- a/WWW/Library/Implementation/HTTCP.c
+++ b/WWW/Library/Implementation/HTTCP.c
@@ -1089,6 +1089,7 @@ PUBLIC struct hostent * LYGetHostByName ARGS1(
     {
 	HANDLE hThread, dwThreadID;
 
+#ifndef __CYGWIN__
 	if (!system_is_NT) {	/* for Windows9x */
 	    unsigned long t;
 	    t = (unsigned long)inet_addr(host);
@@ -1097,6 +1098,7 @@ PUBLIC struct hostent * LYGetHostByName ARGS1(
 	    else
 		phost = gethostbyname(host);
 	} else {		/* for Windows NT */
+#endif /* !__CYGWIN__ */
 	    phost = (struct hostent *) NULL;
 	    donelookup = FALSE;
 	    hThread = CreateThread((void *)NULL, 4096UL,
@@ -1118,7 +1120,9 @@ PUBLIC struct hostent * LYGetHostByName ARGS1(
 		    return NULL;
 		}
 	    }
+#ifndef __CYGWIN__
 	}
+#endif /* !__CYGWIN__ */
 	if (phost) {
 	    lynx_nsl_status = HT_OK;
 	    result_phost = phost;
diff --git a/WWW/Library/Implementation/HTTP.c b/WWW/Library/Implementation/HTTP.c
index 51450145..3562801e 100644
--- a/WWW/Library/Implementation/HTTP.c
+++ b/WWW/Library/Implementation/HTTP.c
@@ -675,6 +675,16 @@ use_tunnel:
       first_Accept = FALSE;
       len = 0;
 
+      /*
+       * FIXME:  suppressing the "Accept-Encoding" in this case is done to work
+       * around limitations of the presentation logic used for the command-line
+       * "-base" option.  The remote site may transmit the document gzip'd, but
+       * the ensuing logic in HTSaveToFile() would see the mime-type as gzip
+       * rather than text/html, and not prepend the base URL.  This is less
+       * efficient than accepting the compressed data and uncompressing it,
+       * adding the base URL but is simpler than augmenting the dump's
+       * presentation logic -TD
+       */
       if (!LYPrependBaseToSource)
 	  HTSprintf(&command, "Accept-Encoding: %s, %s%c%c",
 		    "gzip", "compress", CR, LF);
diff --git a/WWW/Library/Implementation/HTUtils.h b/WWW/Library/Implementation/HTUtils.h
index 8172a750..e038e1b7 100644
--- a/WWW/Library/Implementation/HTUtils.h
+++ b/WWW/Library/Implementation/HTUtils.h
@@ -501,6 +501,7 @@ extern int WWW_TraceMask;
 #define TRACE_SGML      (TRACE_bit(0))
 #define TRACE_STYLE     (TRACE_bit(1))
 #define TRACE_TRST      (TRACE_bit(2))
+#define TRACE_CFG       (TRACE_bit(3))
 
 #if defined(LY_TRACELINE)
 #define LY_SHOWWHERE fprintf( tfp, "%s: %d: ", __FILE__, LY_TRACELINE ),