From 7637f98be2f0f15f67afc707e9dc04a1dd0e2539 Mon Sep 17 00:00:00 2001 From: Antony Dovgal Date: Thu, 28 Dec 2006 22:36:59 +0000 Subject: [PATCH] MFH --- sapi/cgi/cgi_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index 248b9ef37d..4ba48bc0bf 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -811,7 +811,7 @@ static void init_request_info(TSRMLS_D) int l = strlen(env_document_root); int path_translated_len = 0; char *path_translated = NULL; - if (env_document_root[l-1]=='/') { + if (l && env_document_root[l-1]=='/') { --l; } -- 2.50.1