From bc7f9c90263523dc9c19c63c520cbc8f46c3cbdb Mon Sep 17 00:00:00 2001 From: Dai Sato Date: Wed, 5 Apr 2006 14:18:53 +0000 Subject: apply multiple patches on w3m-dev(-en) ML since Jun 2005 to Jan 2006. --- local.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'local.c') diff --git a/local.c b/local.c index b1e388d..e3b9260 100644 --- a/local.c +++ b/local.c @@ -1,4 +1,4 @@ -/* $Id: local.c,v 1.31 2003/09/26 17:59:51 ukai Exp $ */ +/* $Id: local.c,v 1.32 2006/04/05 14:18:54 inu Exp $ */ #include "fm.h" #include #include @@ -16,6 +16,10 @@ #include "local.h" #include "hash.h" +#ifdef __MINGW32_VERSION +#include +#endif + #define CGIFN_NORMAL 0 #define CGIFN_LIBDIR 1 #define CGIFN_CGIBIN 2 @@ -193,8 +197,10 @@ check_local_cgi(char *file, int status) return -1; if (S_ISDIR(st.st_mode)) return -1; +#ifndef __MINGW32_VERSION if ((st.st_uid == geteuid() && (st.st_mode & S_IXUSR)) || (st.st_gid == getegid() && (st.st_mode & S_IXGRP)) || (st.st_mode & S_IXOTH)) /* executable */ return 0; +#endif return -1; } @@ -353,6 +359,9 @@ localcgi_post(char *uri, char *qstr, FormList *request, char *referer) pid_t pid; char *file = uri, *name = uri, *path_info = NULL, *tmpf = NULL; +#ifdef __MINGW32_VERSION + return NULL; +#else status = cgi_filename(uri, &file, &name, &path_info); if (check_local_cgi(file, status) < 0) return NULL; @@ -412,4 +421,5 @@ localcgi_post(char *uri, char *qstr, FormList *request, char *referer) file, mybasename(file), strerror(errno)); exit(1); return NULL; +#endif } -- cgit v1.2.3