Make ao2 global objects not always use the debug version of the ao2_ref() calls.

The debug versions of ao2_ref() should only be used if REF_DEBUG is
enabled so nothing is written to /tmp/refs unexpectedly.

(closes issue ASTERISK-21785)
Reported by: abelbeck
Patches:
      jira_asterisk_21785_v11.patch (license #5621) patch uploaded by rmudgett
Tested by: abelbeck
........

Merged revisions 388700 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: http://svn.asterisk.org/svn/asterisk/trunk@388701 f38db490-d61c-443f-a65b-d21fe96a405b