Slightly changed the callback function typedef to name the type compare_keys, hopefully clarifies the intent.