gio/tests/socket: fix minor memleak