]> git.pld-linux.org Git - packages/lynx.git/commitdiff
- this patch allow view html.gz files
authorjuandon <witekfl@pld-linux.org>
Wed, 3 Jul 2002 12:52:33 +0000 (12:52 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
  if filename doesn't end with .gz and file doesn't exist
  .gz suffix is appended to filename

Changed files:
    lynx-gzip_fallback.patch -> 1.1

lynx-gzip_fallback.patch [new file with mode: 0644]

diff --git a/lynx-gzip_fallback.patch b/lynx-gzip_fallback.patch
new file mode 100644 (file)
index 0000000..e298b8f
--- /dev/null
@@ -0,0 +1,22 @@
+--- lynx2-8-5/WWW/Library/Implementation/HTFile.c.orig Sun Jun 30 23:38:06 2002
++++ lynx2-8-5/WWW/Library/Implementation/HTFile.c      Sun Jun 30 23:46:16 2002
+@@ -2495,9 +2495,18 @@
+       */
+       if (HTStat(localname,&dir_info) == -1)     /* get file information */
+       {
+-                              /* if can't read file information */
++      
++          char *tmp_localname = (char *)malloc(strlen(localname) + 4);
+           CTRACE((tfp, "HTLoadFile: can't stat %s\n", localname));
++          if (tmp_localname) {
++              stpcpy( stpcpy( tmp_localname, localname), ".gz" );
++              FREE(localname);
++              localname = tmp_localname;
++          }
++          /* if can't read file information */
++          
++
+       }  else {               /* Stat was OK */
+           if (S_ISDIR(dir_info.st_mode)) {
This page took 0.075919 seconds and 4 git commands to generate.