dhcpcd-gtk HEAD loops endlessly on start

Hanno Zysik

Fri Nov 27 20:09:38 2020

Hi all!

I just wanted to report that dhcpcd-gtk build from HEAD loops endlessly
on start with open/close connection messages.

Bad commit is:

Bad Hunk from src/libdhcpcd/dhcpcd.c
@@ -1063,8 +1070,10 @@ dhcpcd_open(DHCPCD_CONNECTION *con, bool privileged)
 	memcpy(&nifs, cmd, sizeof(nifs));
 	/* We don't dispatch each interface here as that
 	 * causes too much notification spam when the GUI starts */
-	for (n = 0; n < nifs; n++)
-		dhcpcd_read_if(con, con->command_fd);
+	for (n = 0; n < nifs; n++) {
+		if (dhcpcd_read_if(con, con->command_fd) == NULL)
+			goto err_exit;
+	}

 	update_status(con, DHC_UNKNOWN);

Reversed that hunk and dhcpcd-gtk starts just fine.

Kind regards,
Hanno Zysik

Software Entwickler/Software engineer
Dipl.-Ing. IT (FH)/University of applied sciences

Re: dhcpcd-gtk HEAD loops endlessly on startRoy Marples
Archive administrator: postmaster@marples.name