On Tue, 18 Sep 2001, lo-tek @pb1.pair.com cshmoove wrote:
suppose i have a function which returns a pointer to a variable in
thread
local storage
foo_t *get_global_foo()
{
TSRMLS_FETCH();
return (foo_t *)BAR_G(foo);
}
void fubar()
{
foo_t *foo =
My concern is really with the globals and not the functions, so if two
threads cant simultaneously step on the same copy of globals referenced by a
tsrm resource id, then that solves my problem.
you then pass to bar). So thread safety should *not* be affected.
But AFAIK TSRM* do NOT force
On Wed, 19 Sep 2001, it was written:
My concern is really with the globals and not the functions, so if two
threads cant simultaneously step on the same copy of globals referenced by a
tsrm resource id, then that solves my problem.
Then your problem is solved. Each execution of a script runs
suppose i have a function which returns a pointer to a variable in thread
local storage
foo_t *get_global_foo()
{
TSRMLS_FETCH();
return (foo_t *)BAR_G(foo);
}
void fubar()
{
foo_t *foo = get_global_foo();
bar( foo );/* possible multi-thread access */
}
is fubar then
On Tue, 18 Sep 2001, lo-tek @pb1.pair.com cshmoove wrote:
suppose i have a function which returns a pointer to a variable in thread
local storage
foo_t *get_global_foo()
{
TSRMLS_FETCH();
return (foo_t *)BAR_G(foo);
}
void fubar()
{
foo_t *foo = get_global_foo();