You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ta...@apache.org on 2009/06/03 15:00:26 UTC
svn commit: r781356 - in /httpd/mod_fcgid/trunk/mod_fcgid:
arch/unix/fcgid_proc_unix.c fcgid_bridge.c fcgid_pm.h fcgid_proctbl.h
fcgid_spawn_ctl.c
Author: takashi
Date: Wed Jun 3 13:00:26 2009
New Revision: 781356
URL: http://svn.apache.org/viewvc?rev=781356&view=rev
Log:
Add const qualifier to some strings.
Modified:
httpd/mod_fcgid/trunk/mod_fcgid/arch/unix/fcgid_proc_unix.c
httpd/mod_fcgid/trunk/mod_fcgid/fcgid_bridge.c
httpd/mod_fcgid/trunk/mod_fcgid/fcgid_pm.h
httpd/mod_fcgid/trunk/mod_fcgid/fcgid_proctbl.h
httpd/mod_fcgid/trunk/mod_fcgid/fcgid_spawn_ctl.c
Modified: httpd/mod_fcgid/trunk/mod_fcgid/arch/unix/fcgid_proc_unix.c
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/mod_fcgid/arch/unix/fcgid_proc_unix.c?rev=781356&r1=781355&r2=781356&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/mod_fcgid/arch/unix/fcgid_proc_unix.c (original)
+++ httpd/mod_fcgid/trunk/mod_fcgid/arch/unix/fcgid_proc_unix.c Wed Jun 3 13:00:26 2009
@@ -43,8 +43,8 @@
{
int i = 0;
const char **newargs;
- char *newprogname;
- char *execuser, *execgroup;
+ const char *newprogname;
+ const char *execuser, *execgroup;
const char *argv0;
if (!unixd_config.suexec_enabled) {
@@ -156,9 +156,10 @@
char key_name[_POSIX_PATH_MAX];
void *dummy;
int argc;
- char *wargv[APACHE_ARG_MAX], *word; /* For wrapper */
+ const char *wargv[APACHE_ARG_MAX];
+ const char *word; /* For wrapper */
const char *tmp;
- char *argv[2];
+ const char *argv[2];
/* Build wrapper args */
argc = 0;
@@ -327,8 +328,7 @@
procinfo->cgipath, lpszwapper);
if ((rv =
fcgid_create_privileged_process(procnode->proc_id,
- wargv[0],
- (const char *const *) wargv,
+ wargv[0], wargv,
(const char *const *)
proc_environ, procattr,
procinfo,
@@ -346,7 +346,7 @@
if ((rv =
fcgid_create_privileged_process(procnode->proc_id,
procinfo->cgipath,
- (const char *const *) argv,
+ argv,
(const char *const *)
proc_environ, procattr,
procinfo,
@@ -366,11 +366,11 @@
apr_pool_userdata_get(&dummy, key_name, g_inode_cginame_map);
if (!dummy) {
/* Insert a new item if key not found */
- char *put_key = apr_psprintf(g_inode_cginame_map, "%lX%lX",
- procnode->inode,
- (unsigned long) procnode->deviceid);
- char *fcgipath = apr_psprintf(g_inode_cginame_map, "%s",
- procinfo->cgipath);
+ const char *put_key = apr_psprintf(g_inode_cginame_map, "%lX%lX",
+ procnode->inode,
+ (unsigned long) procnode->deviceid);
+ const char *fcgipath = apr_psprintf(g_inode_cginame_map, "%s",
+ procinfo->cgipath);
if (put_key && fcgipath)
apr_pool_userdata_set(fcgipath, put_key, NULL,
@@ -756,8 +756,8 @@
proc_print_exit_info(fcgid_procnode * procnode, int exitcode,
apr_exit_why_e exitwhy, server_rec * main_server)
{
- char *cgipath = NULL;
- char *diewhy = NULL;
+ const char *cgipath = NULL;
+ const char *diewhy = NULL;
char signal_info[HUGE_STRING_LEN];
char key_name[_POSIX_PATH_MAX];
int signum = exitcode;
Modified: httpd/mod_fcgid/trunk/mod_fcgid/fcgid_bridge.c
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/mod_fcgid/fcgid_bridge.c?rev=781356&r1=781355&r2=781356&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/mod_fcgid/fcgid_bridge.c (original)
+++ httpd/mod_fcgid/trunk/mod_fcgid/fcgid_bridge.c Wed Jun 3 13:00:26 2009
@@ -51,7 +51,7 @@
uid_t uid = command->uid;
gid_t gid = command->gid;
apr_size_t share_grp_id = command->share_grp_id;
- char *virtualhost = command->virtualhost;
+ const char *virtualhost = command->virtualhost;
proc_table = proctable_get_table_array();
previous_node = proctable_get_idle_list();
Modified: httpd/mod_fcgid/trunk/mod_fcgid/fcgid_pm.h
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/mod_fcgid/fcgid_pm.h?rev=781356&r1=781355&r2=781356&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/mod_fcgid/fcgid_pm.h (original)
+++ httpd/mod_fcgid/trunk/mod_fcgid/fcgid_pm.h Wed Jun 3 13:00:26 2009
@@ -28,7 +28,7 @@
apr_ino_t inode;
dev_t deviceid;
apr_size_t share_grp_id;
- char *virtualhost; /* Virtualhost granularity */
+ const char *virtualhost; /* Virtualhost granularity */
uid_t uid; /* For suEXEC */
gid_t gid; /* For suEXEC */
int userdir; /* For suEXEC */
Modified: httpd/mod_fcgid/trunk/mod_fcgid/fcgid_proctbl.h
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/mod_fcgid/fcgid_proctbl.h?rev=781356&r1=781355&r2=781356&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/mod_fcgid/fcgid_proctbl.h (original)
+++ httpd/mod_fcgid/trunk/mod_fcgid/fcgid_proctbl.h Wed Jun 3 13:00:26 2009
@@ -45,7 +45,7 @@
gid_t gid; /* for suEXEC */
uid_t uid; /* for suEXEC */
apr_size_t share_grp_id; /* cgi wrapper share group id */
- char *virtualhost; /* the virtualhost this process belongs to */
+ const char *virtualhost; /* the virtualhost this process belongs to */
apr_time_t start_time; /* the time of this process create */
apr_time_t last_active_time; /* the time this process last active */
int requests_handled; /* number of requests process has handled */
Modified: httpd/mod_fcgid/trunk/mod_fcgid/fcgid_spawn_ctl.c
URL: http://svn.apache.org/viewvc/httpd/mod_fcgid/trunk/mod_fcgid/fcgid_spawn_ctl.c?rev=781356&r1=781355&r2=781356&view=diff
==============================================================================
--- httpd/mod_fcgid/trunk/mod_fcgid/fcgid_spawn_ctl.c (original)
+++ httpd/mod_fcgid/trunk/mod_fcgid/fcgid_spawn_ctl.c Wed Jun 3 13:00:26 2009
@@ -26,7 +26,7 @@
uid_t uid;
gid_t gid;
apr_size_t share_grp_id;
- char *virtualhost;
+ const char *virtualhost;
int score;
int process_counter;
apr_time_t last_stat_time;