From FreeSWITCH Wiki
I decided to look at the code to see exactly what was being done to implement this. I found was that there was no code at all to implement the 3rd optional parameter.
I also decided that an implementation that did not involve mutex protection was not a adequate solution. So, I created a proposed change to spider_monkey and to the switch_core to implement a mutex protected version of the code. Submitted a JIRA with a jira diff. This was taken by the great developer of FreeSWITCH (Anthony Minessale) who proceeded to make a better version of the change and provide the capability to anyone else that would want to use Switch Global Variables.