www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vaclav Ovsik <Vaclav.Ov...@i.cz>
Subject Re: os-windows/9458: apache cannot execute cgi on path witch not fit into 8.3 limitation on NTFS on WinNT4.0.
Date Mon, 14 Jan 2002 11:14:20 GMT
This patch solves the problem:

***********<snip>***********
--- src/main/util_script.c.orig	Mon Jan 14 09:39:03 2002
+++ src/main/util_script.c	Mon Jan 14 09:55:16 2002
@@ -1000,12 +1000,15 @@
             {
                 char shortname[MAX_PATH];
                 DWORD rv = GetShortPathName(r->filename, shortname, MAX_PATH);
-                if (!rv || rv >= MAX_PATH) {
+                if ((!rv && strlen(r->filename) >= MAX_PATH)
+                        || rv >= MAX_PATH) {
                     ap_log_rerror(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, r,
                                   "%s is not executable; cannot translate "
                                   "to a short path name.", r->filename);
                     return (pid);
                 }
+                if (!rv)
+                    strcpy(shortname, r->filename);
                 invokename = ap_pstrdup(r->pool, shortname);
 
                 if (interpreter && *interpreter
***********<snip>***********

-- 
	Vaclav Ovsik		email: Vaclav.Ovsik@i.cz
	ICZ a.s.		phone: +420 19 7488511
				fax:   +420 19 7488506


Mime
View raw message