VectorComparer should check null

This is:
  https://codereview.chromium.org/332113002
Add methods for obtaining the C runtime heap handle