Re: [gnome-network]IPV6 fix for scan (with patch)



Carlos Garcia Campos wrote:
It doesn't work for IPv6. I don't know the reason but using a "size"
variable instead of sizeof in the connect system call, it works
perfectly for IPv4 and IPv6 (in my system). I have attached the patch

Yes it is better.  I have committed my patch with your suggestion.  Thanks.

However, I have a question about your patch.

Index: scan.c
===================================================================
RCS file: /cvs/gnome/gnome-network/gnome-netinfo/scan.c,v
retrieving revision 1.6
diff -u -u -r1.6 scan.c
--- scan.c	2 Oct 2003 21:26:16 -0000	1.6
+++ scan.c	18 Nov 2003 13:33:25 -0000
@@ -64,9 +64,16 @@
	gchar buf[SIZE];
	gchar *service_name = NULL;
	gint ip_version, pf;
+	struct sockaddr *addr_ptr;
+	gint size;

	g_return_if_fail (netinfo != NULL);

+	if (netinfo_validate_host (netinfo) == FALSE) {
+		netinfo_stop_process_command (netinfo);
+		return;
+	}

What is the above for? It looks like something that we could use. I think providing some feedback to the user when they have entered an invalid hostname is a really good thing. Is that what this is for? Do you have a complete patch for this functionality?

Jon




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]