apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <traw...@attglobal.net>
Subject apr_table_overlap and pool ancestor assumption
Date Mon, 16 Sep 2002 18:13:33 GMT
What will happen if keys and values in b are NOT from an ancestor of
a's pool but b has sufficient lifetime?

I'm debugging a segfault in hash_overlap() when driven by a 3rd party
Apache module.  Clearly the 3rd party module is misusing
apr_table_overlap() because a is from the request pool and b is from
pconf, which is in essence a storage leak because pconf shouldn't
grow.

I can't explain the actual segfault, though.  In the segfaulting
scenario, which is very intermittent, some pointers (tree_parent,
merge_left) in the hash table created in apr_table_overlap are
actually literal strings from the table.  These could also be hashes
of the strings.

Does anybody understand this code well enough to describe what bad
will happen besides a storage leak in this scenario?  pconf isn't
going away, so there doesn't seem to be a storage lifetime problem.

-- 
Jeff Trawick | trawick@attglobal.net
Born in Roswell... married an alien...

Mime
View raw message