Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Cancel the alarm when the progressbar is done
Bryan Drewery committed 11 years ago
commit bf68e0df9d7187f096f25786ea397297cf1ee34b
parent a2d8f4bbce21d4eb789112964667daf403d33159
1 file changed +3 -3
modified src/event.c
@@ -394,7 +394,8 @@ progressbar_stop(void)
			printf(" done");
		putchar('\n');
	}
-

+
	if (progress_alarm)
+
		alarm(0);
	last_progress_percent = -1;
	progress_alarm = false;
	progress_started = false;
@@ -503,9 +504,8 @@ draw_progressbar(int64_t current, int64_t total)
		}
		fflush(stdout);
	}
-
	if (current >= total) {
+
	if (current >= total)
		progressbar_stop();
-
	}
	else if (!progress_alarm && progress_started) {
		/* Setup auxiliary alarm */
		struct sigaction sa;