Refactor SRU/Z39.50 diag map utils to diag_map.c