[SNIP]
Thanks for answering. I really don't need a multi threaded env in aI'm not sure up to which point a global variable might become a
sense that
no mutex or locking is needed. *However there can be many users & so
per user(per thread)
context can be there. *Though at present i am forking a new process
for each user, rather than creating a new thread. But as i have no
global at present, i can do the other option equally well.
I "think" for both option 1) & option 3) a per thread context has no
problem.
I am fearing that, and really trying to avoid global variables mostly
because i am not sure of performance of global in inner loop (also
some platform doesn't support global Symbian? )
runtime bottleneck. That would have to be checked for your case &
compiler. However, I'd stay away from global variables as much as
possible and go with singletons as you have much better control.
As you say that you will not tread into the depths of mutexes & locks,
I would say that your first option should do the trick just fine.
Cheers
Chris