Ensure that 'count_total' is available throughout `bp_has_activities()` loop.

Props tharsheblows.
Fixes #5915.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@9169 cdf35c40-ae34-48e0-9cc9-0c9da1808c22