[mod_cluster-issues] [JBoss JIRA] (MODCLUSTER-613) mod_cluster_slotmem doesn't use the same ftok() than apr
Jean-Frederic Clere (JIRA)
issues at jboss.org
Mon Aug 21 10:31:00 EDT 2017
[ https://issues.jboss.org/browse/MODCLUSTER-613?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13452056#comment-13452056 ]
Jean-Frederic Clere commented on MODCLUSTER-613:
------------------------------------------------
looking in sharedmem_util.c:
+++
apr_status_t unixd_set_shm_perms(const char *fname)
{
#ifdef AP_NEED_SET_MUTEX_PERMS
#if APR_USE_SHMEM_SHMGET || APR_USE_SHMEM_SHMGET_ANON
struct shmid_ds shmbuf;
key_t shmkey;
int shmid;
shmkey = ftok(fname, 1);
+++
and looking in apr-1.5.x there is:
+++
#if APR_USE_SHMEM_SHMGET
static key_t our_ftok(const char *filename)
{
/* to help avoid collisions while still using
* an easily recreated proj_id */
apr_ssize_t slen = strlen(filename);
return ftok(filename,
(int)apr_hashfunc_default(filename, &slen));
}
#endif
+++
That looks fishy....
> mod_cluster_slotmem doesn't use the same ftok() than apr
> --------------------------------------------------------
>
> Key: MODCLUSTER-613
> URL: https://issues.jboss.org/browse/MODCLUSTER-613
> Project: mod_cluster
> Issue Type: Bug
> Components: Native (httpd modules)
> Reporter: Jean-Frederic Clere
> Assignee: Jean-Frederic Clere
>
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
More information about the mod_cluster-issues
mailing list