summary refs log tree commit diff
path: root/OpenBSD/www/cgit-pink/patches/patch-setup_c
blob: eae3fc06adcebf408cf5f742eab5ce9cf6a84dc5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
$OpenBSD: patch-setup_c,v 1.1 2017/03/22 20:23:52 landry Exp $

Dont openbsd dev/null, doesnt exist in the default chroot

--- git/setup.c.orig	Wed Mar  1 21:01:06 2017
+++ git/setup.c	Wed Mar  1 21:01:56 2017
@@ -1488,11 +1488,13 @@ const char *resolve_gitdir_gently(const char *suspect, int *return_error_code)
 /* if any standard file descriptor is missing open it to /dev/null */
 void sanitize_stdfds(void)
 {
+#if 0
 	int fd = xopen("/dev/null", O_RDWR);
 	while (fd < 2)
 		fd = xdup(fd);
 	if (fd > 2)
 		close(fd);
+#endif
 }
 
 int daemonize(void)