When doing parallel builds using GNU Make, jumping to the location of a warning/error from the compilation buffer often does not work. This is because GNU Make enters different directories at the same time, and the resulting output is intermixed. The attached patch fixes this by looking at all directories which were entered up to the point of the warning/error, instead of just taking the directly preceding one. I'm aware that this is not a perfect solution, since those directories might contain files with identical names, in which case Emacs might show the wrong one, but IMO it's still an improvement over the current situation. This feature can also be disabled through a new variable. -David