Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Do not try to call kevent if not on ssh
Baptiste Daroussin committed 13 years ago
commit d9a542d7717a5a8953d545f46728b902637f8ecd
parent b03f667c0782a10ef0cd35dcad06a76b47374b66
1 file changed +3 -2
modified libpkg/fetch.c
@@ -398,8 +398,9 @@ pkg_fetch_file_to_fd(struct pkg_fetch *f, const char *url, int dest, time_t *t)

	cleanup:

-
	if (strcmp(u->scheme, "ssh") != 0 && remote != NULL) {
-
		fclose(remote);
+
	if (strcmp(u->scheme, "ssh") != 0) {
+
		if (remote != NULL)
+
			fclose(remote);
	} else {
		EV_SET(&e, fileno(f->ssh), EVFILT_READ, EV_DELETE, 0, 0, 0);
		kevent(kq, &e, 1, NULL, 0, NULL);