httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject cvs commit: httpd-2.0/modules/generators mod_autoindex.c
Date Sun, 19 Aug 2001 18:58:19 GMT
wrowe       01/08/19 11:58:19

  Modified:    modules/generators mod_autoindex.c
  Log:
    Assure that non-FancyIndexed listings properly shortcut dir entries,
    and display and href the trailing slash, as well.
  
  PR: 8206
  
  Revision  Changes    Path
  1.86      +4 -2      httpd-2.0/modules/generators/mod_autoindex.c
  
  Index: mod_autoindex.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/generators/mod_autoindex.c,v
  retrieving revision 1.85
  retrieving revision 1.86
  diff -u -r1.85 -r1.86
  --- mod_autoindex.c	2001/08/19 05:48:18	1.85
  +++ mod_autoindex.c	2001/08/19 18:58:19	1.86
  @@ -1269,7 +1269,10 @@
       }
   
       p = (struct ent *) apr_pcalloc(r->pool, sizeof(struct ent));
  -    p->name = apr_pstrdup(r->pool, dirent->name);
  +    if (rr->finfo.filetype == APR_DIR)
  +        p->name = apr_pstrcat(r->pool, dirent->name, "/", NULL);
  +    else
  +        p->name = apr_pstrdup(r->pool, dirent->name);
       p->size = -1;
       p->icon = NULL;
       p->alt = NULL;
  @@ -1293,7 +1296,6 @@
   		if (!(p->alt = find_default_alt(d, "^^DIRECTORY^^")))
   		    p->alt = "DIR";
   	    }
  -	    p->name = apr_pstrcat(r->pool, dirent->name, "/", NULL);
   	}
   	else {
   	    p->icon = find_icon(d, rr, 0);
  
  
  

Mime
View raw message