Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
Check rc_file != NULL
Baptiste Daroussin committed 14 years ago
commit e8db4d0ca19a4af46b70485a452a9aa3b85a1cf3
parent 39782c5
1 file changed +6 -0
modified libpkg/rcscripts.c
@@ -67,6 +67,9 @@ rc_stop(const char *rc_file)
	int fd;
	pid_t pid;

+
	if (rc_file == NULL)
+
		return (0);
+

	switch ((pid = fork())) {
		case -1:
			return (-1);
@@ -121,6 +124,9 @@ rc_start(const char *rc_file)
	int pstat;
	pid_t pid;

+
	if (rc_file == NULL)
+
		return (0);
+

	switch ((pid = fork())) {
		case -1:
			return (-1);