Checking the length of the string in get_local_socket_name() to make sure we don't overrun the string we're filling in.
Fixing orientation code.  (1) made it right handed, (2) using q_invert and swapping order of application so that the calibration rotation is properly undone.  This makes the orientation changes right handed and match the translation axes.