In some custom code, we call:

taxonomy_vocabulary_machine_name_load('global_vocab_name')

to retrieve the specified global vocabulary. With og_vocab enabled, this stops working. The cause seems to be the og_vocab_query_taxonomy_vocabulary_load_multiple_alter() function which does some odd-looking logic around checking a static cache to see if it's set to 'skip' or not.

Looks like it is trying to restrict the entity_log_multiple to only load vocabs that are associated with the group. But what about global taxonomies? Seems like global taxonomies still work fine (I can add term_reference fields to my content types, etc). But this seems a horrible way to implement something.

In fact, I found that if I call taxonomy_vocabulary_machine_name_load('global_vocab_name') twice in a row, then I get the proper result returned because the second time it is called the static $cache variable is TRUE, which tricks the og_vocab into thinking it is recursing. But calling this function twice to get the correct result seems kludgy. And obviously I don't want to need to set the static og_vocab $cache manually within my own code.

If this is working as intended, then you need to at least add a helper function to set this cache to skip in preparation for somebody else who doesn't want to alter the query. Even better would be figuring out a better way to do this that doesn't cause so many odd consequences.