From: Junio C Hamano Date: Thu, 14 Sep 2006 16:53:36 GMT Subject: Re: [PATCH 2/2] Handle invalid argc gently Message-ID: <7virjq4cfj.fsf@assigned-by-dhcp.cox.net> In-Reply-To: <20060914131626.GE6709@basalt.office.altlinux.org> "Dmitry V. Levin" writes: >> What is the valid reason to do execlp("git", NULL, NULL)? > > Personally I do not plan to execute git this way on regular basis, indeed. :) > > But argc == 0 is allowed, so why should git crash? Oh, no I was not arguing for making git crash. I was just trying to learn if there is a valid reason to choose to, or common misconfiguration that causes it to, run with ac == 0, since I did not think of any. It is good to be extra careful and defensive -- I just wanted to know if there is more to it.