net: tap: replace snprintf with g_strdup_printf calls