code cleanup: use NULL rather then 0 for pointers, and make vars static where possible.
also found unintentionally defined enum/struct variables that where only meant to be defining the type.


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@55493 954f8c5b-7b00-dc11-b283-0030488c597c