This fixes the crash by removing the do_view3d_header_buttons handler.
The code can work at a higher level here, using the operator for setting
the select mode, which makes this patch a cleanup as well.
The only thing that's lost is the custom tooltips for the buttons.
However, I found that clrl-click didn't work as described anyway, and
the shift-select behavior is a common pattern in Blender's UI that
doesn't need special description here, in my opinion. The operator
could get a description callback too, but that might not work as well
when it's called from a button in "exec" context that wouldn't use the
shift key modifier.