You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by tr...@apache.org on 2011/04/15 22:50:57 UTC
svn commit: r1092809 - in /httpd/mod_fcgid/trunk/modules/fcgid:
fcgid_pm_win.c fcgid_proc_win.c fcgid_proctbl_win.c
Author: trawick
Date: Fri Apr 15 20:50:56 2011
New Revision: 1092809
URL: http://svn.apache.org/viewvc?rev=1092809&view=rev
Log:
address gcc warnings in the Windows code
Modified:
httpd/mod_fcgid/trunk/modules/fcgid/fcgid_pm_win.c
httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proc_win.c
httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proctbl_win.c
Modified: httpd/mod_fcgid/trunk/modules/fcgid/fcgid_pm_win.c
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/modules/fcgid/fcgid_pm_win.c?rev=1092809&r1=1092808&r2=1092809&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/modules/fcgid/fcgid_pm_win.c (original)
+++ httpd/mod_fcgid/trunk/modules/fcgid/fcgid_pm_win.c Fri Apr 15 20:50:56 2011
@@ -190,7 +190,7 @@ apr_status_t procmgr_post_spawn_cmd(fcgi
if ((rv =
apr_queue_pop(g_notifyqueue,
- ¬ifybyte)) != APR_SUCCESS) {
+ (void **)¬ifybyte)) != APR_SUCCESS) {
apr_thread_mutex_unlock(g_reqlock);
ap_log_rerror(APLOG_MARK, APLOG_EMERG, rv, r,
"mod_fcgid: can't pop notify message");
@@ -226,11 +226,10 @@ apr_status_t procmgr_finish_notify(serve
apr_status_t procmgr_peek_cmd(fcgid_command * command,
server_rec * main_server)
{
- apr_status_t rv = APR_SUCCESS;
fcgid_command *peakcmd = NULL;
if (!g_must_exit && g_msgqueue) {
- if (apr_queue_pop(g_msgqueue, &peakcmd) == APR_SUCCESS) {
+ if (apr_queue_pop(g_msgqueue, (void **)&peakcmd) == APR_SUCCESS) {
if (!peakcmd)
return APR_TIMEUP; /* This a wake up message */
else {
@@ -273,7 +272,7 @@ apr_status_t procmgr_stop_procmgr(void *
/* Free the memory left in queue */
fcgid_command *peakcmd = NULL;
- while (apr_queue_trypop(g_msgqueue, &peakcmd) == APR_SUCCESS) {
+ while (apr_queue_trypop(g_msgqueue, (void **)&peakcmd) == APR_SUCCESS) {
if (peakcmd)
free(peakcmd);
}
Modified: httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proc_win.c
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proc_win.c?rev=1092809&r1=1092808&r2=1092809&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proc_win.c (original)
+++ httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proc_win.c Fri Apr 15 20:50:56 2011
@@ -62,15 +62,14 @@ apr_status_t proc_spawn_process(const ch
fcgid_procnode *procnode)
{
HANDLE *finish_event, listen_handle;
- int bufused = 0;
SECURITY_ATTRIBUTES SecurityAttributes;
apr_procattr_t *proc_attr;
apr_status_t rv;
apr_file_t *file;
- char **proc_environ;
+ const char * const *proc_environ;
char sock_path[FCGID_PATH_MAX];
int argc;
- char *wargv[APACHE_ARG_MAX + 1], *word; /* For wrapper */
+ char const * wargv[APACHE_ARG_MAX + 1], *word; /* For wrapper */
const char *tmp;
/* Build wrapper args */
@@ -112,7 +111,7 @@ apr_status_t proc_spawn_process(const ch
/* Prepare the listen namedpipe file name (no check for truncation) */
apr_snprintf(sock_path, sizeof sock_path,
- "\\\\.\\pipe\\fcgidpipe-%u.%lu",
+ "\\\\.\\pipe\\fcgidpipe-%lu.%d",
GetCurrentProcessId(), g_process_counter++);
/* Prepare the listen namedpipe handle */
@@ -135,7 +134,8 @@ apr_status_t proc_spawn_process(const ch
sizeof(procnode->executable_path));
/* Build environment variables */
- proc_environ = ap_create_environment(procnode->proc_pool,
+ proc_environ = (const char * const *)
+ ap_create_environment(procnode->proc_pool,
procinfo->proc_environ);
if (!proc_environ) {
ap_log_error(APLOG_MARK, APLOG_WARNING, apr_get_os_error(),
@@ -168,7 +168,8 @@ apr_status_t proc_spawn_process(const ch
/* fork and exec now */
rv = apr_proc_create(&(procnode->proc_id), wargv[0], wargv,
- proc_environ, proc_attr, procnode->proc_pool);
+ proc_environ,
+ proc_attr, procnode->proc_pool);
/* OK, I created the process, now put it back to idle list */
CloseHandle(listen_handle);
@@ -381,7 +382,7 @@ apr_status_t proc_write_ipc(fcgid_ipc *
bucket_request != APR_BRIGADE_SENTINEL(birgade_send);
bucket_request = APR_BUCKET_NEXT(bucket_request))
{
- char *write_buf;
+ const char *write_buf;
apr_size_t write_buf_len;
apr_size_t has_write;
Modified: httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proctbl_win.c
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proctbl_win.c?rev=1092809&r1=1092808&r2=1092809&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proctbl_win.c (original)
+++ httpd/mod_fcgid/trunk/modules/fcgid/fcgid_proctbl_win.c Fri Apr 15 20:50:56 2011
@@ -81,47 +81,47 @@ proctable_child_init(server_rec * main_s
return APR_SUCCESS;
}
-static apr_status_t proctable_lock_internal()
+static apr_status_t proctable_lock_internal(void)
{
return apr_thread_mutex_lock(g_sharelock);
}
-static apr_status_t proctable_unlock_internal()
+static apr_status_t proctable_unlock_internal(void)
{
return apr_thread_mutex_unlock(g_sharelock);
}
-fcgid_procnode *proctable_get_free_list()
+fcgid_procnode *proctable_get_free_list(void)
{
return g_free_list_header;
}
-fcgid_procnode *proctable_get_busy_list()
+fcgid_procnode *proctable_get_busy_list(void)
{
return g_busy_list_header;
}
-fcgid_procnode *proctable_get_idle_list()
+fcgid_procnode *proctable_get_idle_list(void)
{
return g_idle_list_header;
}
-fcgid_procnode *proctable_get_table_array()
+fcgid_procnode *proctable_get_table_array(void)
{
return g_proc_array;
}
-fcgid_procnode *proctable_get_error_list()
+fcgid_procnode *proctable_get_error_list(void)
{
return g_error_list_header;
}
-fcgid_global_share *proctable_get_globalshare()
+fcgid_global_share *proctable_get_globalshare(void)
{
return g_global_share;
}
-size_t proctable_get_table_size()
+size_t proctable_get_table_size(void)
{
return g_table_size;
}