Call TROOT::GetGlobalFunction instead of GetListOfGlobalFunctions

Since the global function list needs to be locked to be thread safe,
the simplest way of avoiding having to take the locks outside of
TROOT is to call GetGlobalFunction instead.
Lock access to gROOT->fGlobalFunctions

The list of global functions must be protected from simultaneous
writes/reads.
Merge pull request #32 from Dr15Jones/lockAccessToGlobalFunctionsList_v5-34-21

Lock access to global functions list