Thread (21 messages) flat view 21 messages, 9 authors, 2016-06-15

Re: git-commit fatal: Out of memory? mmap failed: Bad file descriptor

From: Linus Torvalds <torvalds@linux-foundation.org>
Date: 2016-06-15 22:44:05


On Tue, 15 Jan 2008, Brandon Casey wrote:
In that same vein, just above your changes in prepare_index() is:

	if (!pathspec || !*pathspec) {
		fd = hold_locked_index(&index_lock, 1);
		refresh_cache(REFRESH_QUIET);
		if (write_cache(fd, active_cache, active_nr) ||
		    close(fd) || commit_locked_index(&index_lock))
			die("unable to write new_index file");
		commit_style = COMMIT_AS_IS;
		return get_index_file();
	}
Yeah, I think that may be the one that got you. I obviously couldn't 
follow the exact path through the code, I was just looking at the trace of 
system calls and found that one thing that looked like it was your case, 
but it's entirely possible that it was another path of the index lock file 
that causes it.

Your patch seems "ObviouslyCorrect(tm)".

		Linus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help